TrueJournals

Archive for October, 2013

Let the Language Work for You – Part 1: C++ Destructors

by on Oct.10, 2013, under programming

I recently came across a programming design pattern I hadn’t thought of, and that inspired me to write at least one blog post.  So, I introduce this post which may or may not start a series of posts, entitled “Letting the Language Work for You”.

The idea behind this series is this: programming languages have become very advanced, possibly more than most people realize.  There are many things you may be doing now in your programs that are simply extra work that you don’t really need to do.  Instead, you should let the language do the work for you.  These posts will (hopefully) help you take full advantage of your programming language to avoid extra work, and hopefully keep out some bugs.

For part 1, let’s look at destructors in C++.  Before we get started, I’ll note that this post is very much inspired by Boost’s ScopedLock pattern.  If you know where this is headed just by reading that, I’ll understand if you decide you don’t need to read what I have to say.  Otherwise, if you use an object oriented language, I’d encourage you to keep going.

(continue reading…)

Leave a Comment :, , more...

Inside the Acer Aspire M5-583P

by on Oct.05, 2013, under hardware, life

I recently got a new laptop.  After a lot of searching, I decided on the Acer Aspire M5-583P.  Overall, it’s a really awesome laptop, and I just couldn’t find anything that came close to the specs for the price ($650 when I got mine).

There was one thing, however, that I was a bit disappointed in: the lack of an SSD cache.  I was curious how easy it would be to replace the HDD, but I didn’t want to open the laptop and void my warranty right away, so I started looking online for pictures of the internals.  Unfortunately, there seems to be nothing available.

So, I finally broke down and opened the laptop myself.  The laptop is super simple to open: just some screws that are easily visible on the back.  After that, you just have to pry the black bottom piece off.  That part is a bit challenging, since it’s protected by little plastic clips, but you can just gently tug at it a bit and it pops right off.

So, I present here… some pictures! (continue reading…)

2 Comments :, , more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...