Welcome to MSDN Blogs Sign in | Join | Help

jaredpar's WebLog

Code, rants and ramblings of a programmer.

Syndication

News

Now Reading

Expert F#

What's a better book to read when learning F#?

Essential WPF

Thus far the best book I've read on WPF. Gets right down to working with WPF and the goals/history.

Purely Functional Data Structures

Reading this book makes me feel like I'm back in college. It will really get your mind going and is best read with a whiteboard handy.

Blog Roll

Eric Lippert
Dustin Campbell
Jon Skeet
Coding Horror
Brian McNamara
Brian Bondy
Hub FS
Full List

Browse by Tags

All Tags » C++ » Patterns   (RSS)
do {} while(0) what?
A recent check in of mine raised a few eye brows during reviews. I checked in a few macros which ended with/contained a "do{}while(0)" and people were curious as to why. In my experience there are two main uses for it. Insert an empty statement with no Read More...

Posted Wednesday, May 21, 2008 8:00 AM by Jared Parsons | 3 Comments

Filed under: ,

API Problems: CComObject::CreateInstance
CComObject::CreateInstance is a light weight method for creating instances of COM objects in your code. Unfortunately the design of the API makes it easy to introduce subtle errors into your code. The two problems are it encourages manually ref counting Read More...

Posted Friday, March 28, 2008 7:38 PM by Jared Parsons | 2 Comments

Filed under: , ,

Multiple paths to IUnknown
ATL has a lot of great tools for COM programming and CComPtr is a good example. It's a smart pointer class which manages the reference count of an underlying COM object. One of it's limitations though is it will only work properly when the inheritance Read More...

Posted Friday, February 22, 2008 1:21 AM by Jared Parsons | 0 Comments

Filed under: , ,

C++ Placement New: Tracking down a crash
See my previous two posts on an introduction to placement new if you are unfamiliar with the subject. http://blogs.msdn.com/jaredpar/archive/2007/10/16/c-new-operator-and-placement-new.aspx http://blogs.msdn.com/jaredpar/archive/2007/10/17/c-placement-new-and-allocators.aspx Read More...

Posted Thursday, October 18, 2007 1:05 PM by Jared Parsons | 1 Comments

Filed under: , ,

C++ Placement New and Allocators
This is a follow up for my previous post about operator new and placement new. This post will discuss the role of adding a custom allocator and using it with new. It's handy to use custom allocators in C++. Certain operations can be done more efficiently Read More...

Posted Wednesday, October 17, 2007 2:54 PM by Jared Parsons | 2 Comments

Filed under: ,

C++ New Operator and Placement New
Originally I was going to write this article to detail a particular problem I had recently with placement new in C++. A page or two of writing later I decided it would be best to start with an introduction to the "new" operator itself and the in/outs Read More...

Posted Tuesday, October 16, 2007 7:08 PM by Jared Parsons | 5 Comments

Filed under: ,

Page view tracker