Expected function body after function declarator error with Xcode 3.2.4 and iOS 4.1 (and workaround)

In compiling the Feathers Visage target in Xcode 3.2.4 with the iOS 4.1 SDK, I got the following compiler error on my Prefix.pch file:

CGPDFContext.h:60:23: error: expected function body after function declarator

Googling the error, brought up this post on the iPhone Development Blog with a potential solution and a link to a thread the Apple Developer Forums for a different workaround if you're using the LLVM compiler (I am using LLVM 1.5 for Feathers at the moment): llvm compiler no longer works with simulator.

Based on that thread, I added the following two lines to my Prefix.pch file, which fixed the issue:


The interesting thing is that my Feathers target (in the same project) doesn't exhibit the same behavior.