objective-c - NSInteger报警告
漂亮男人
漂亮男人 2017-05-02 09:36:19
0
2
682

警告为: Values of type 'NSInteger' should not be used as format arguments...

漂亮男人
漂亮男人

reply all(2)
迷茫

This is because the types of NSInteger are different under 32-bit and 64-bit platforms. NSInteger is int type under 32-bit platform and long type under 64-bit platform. If you select the 32-bit platform when compiling, (iPhone4, iPhone4s, iPhone5) then this warning will be reported, but if you choose a 64-bit platform (iPhone5s and above), then this warning will not be reported

PHPzhong

Use %zd,NSUinteger用%zu,保证是正整数也可以使用%zi

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template