Game Development Reference
In-Depth Information
Figure 14-10 . The analyze build finds potential issues and makes suggestions on how to fix them
As you may notice from the figure, there seems to be some kind of problem. But the in-
formation shown in the figure doesn't tell you why the analyzer deems this a problem. So
far the logging has worked fine. What could be the problem here, and should you fix it?
Possibly the best tip I can give regarding compiler errors is so obvious I'm afraid to men-
tion it: Google the exact error message. You don't even have to type it back into Google's
search field—every piece of text displayed by Xcode can be copied to the clipboard as
text. Where the regular Cmd+C (Copy) command won't work, there's usually a right-click
context menu with a Copy item.
Tip When you copy strings from Xcode, they may contain specific references
to your project, such as path, file name, line numbers, class, and variable
names. If the search results are unsatisfactory or nothing was found, make sure
you remove those project-specific references and Google only for the raw error
message, stripped of any variable, function, or class names that may exist only
in your own project.
One of the top links from Google Search explains the reason behind the error message: the
NSUInteger data type is a 32-bit ( unsigned int ) type on 32-bit devices and 64-bit
( unsigned long ) on 64-bit devices such as the iPhone 5S. Though the conversion
from unsigned int to unsigned long will occur implicitly, the compiler will never-
theless warn about this conversion when building the 32-bit version of the code. And the
Search WWH ::




Custom Search