c - Is int ever needed on x64? -



c - Is int ever needed on x64? -

c code targeting x64, has been discussed, should utilize size_t instead of int things counts , array indexes.

given that, arguably simpler , less error prone standardize on size_t (typedef'd shorter) instead of int usual integer type across entire code base.

is there i'm missing? assuming don't need signed integers, , you're not storing big arrays of little integers (where making them 32 bits instead of 64 bits save memory), there reason utilize int in preference size_t?

i in contrary, prefer prepare size of integers, uint8_t ... uint64_t (and sometime unit128_t), , these base of operations types. know get.

and other typedef size_t aliasing these. inspect typedef uintprt_t , deduce address width, e.g.

and also, people need signed types sure. relation clarified. in standard, signed types sort of deduced unsigned types. made explicit forcing prefix signed. sure later wouldn't happen, people much emotionally attached int :)

c 64bit

Comments

Popular posts from this blog

java - How to set log4j.defaultInitOverride property to false in jboss server 6 -

c - GStreamer 1.0 1.4.5 RTSP Example Server sends 503 Service unavailable -

Using ajax with sonata admin list view pagination -