Memory Allocation Between iPhone 2G and 3G
<p>In one of my builds for an iPhone app, I had inadvertently created a variable that shadowed a variable in the scope above it.  This was unintentional, but compiled since Objective-C apparently allows shadowing of variables between an if block and its containing method.</p>

<p>When I sent out this code, people that were using iPhone 3Gs immediately encountered problems, but people using 2Gs didn't have any apparent problems.</p>

<p>Does anyone happen to know if there are actual OS differences for these two models?  Do 2Gs have compile-time, static memory allocation, somehow?</p>

<p>This was a huge point of confusion, since I only had a 2G development device, and never encountered a problem, even though theoretically, the code should not have worked as expected.</p>

<p>Now, there are a couple of other differences in that the 3Gs were using builds targetting an AdHoc build, while the ones the 2Gs were using were targetted for Release.</p>
