FBDigitalFont icon indicating copy to clipboard operation
FBDigitalFont copied to clipboard

Implicit conversion loses integer precision: 'NSInteger' (aka "long") to FBFontSymbolType

Open jmmoody opened this issue 10 years ago • 0 comments

In Class FBBitmapFontView.m Method numberOfHorizontalDot on line 72

FBFontSymbolType symbol = (int)[number integerValue];

Generates this warning when in XCODE 5.1.1 when compiling for 64 bit. Makes sense as the size of NSInteger is 8 and the enum is 4 in in this scenario. Looks like to me in this case, this can be safely ignored but if you want the warning to go away just change the line of code to this.

FBFontSymbolType symbol = (int)[number integerValue];

and cast the right hand side back to an int so it matches the enum.

jmmoody avatar Aug 26 '14 21:08 jmmoody