-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Fri, Sep 30, 2005 at 07:44:01AM +1000, Erik de Castro Lopo wrote:
> In addition, C is used for low level programming where the programmer
> needs to be able to address 32 bit hardware registers. If int was
> 64 bits, what would you use for accessing these registers.
^^^^^ (corrected)
You would use int. You would also use a function to access the
hardware register and the function would contain whatever CPU magic
is required to access the register.
The hard problem is when you have a 32 bit number inside a structure
and the structure is packed so you have to access exactly that
particular number with bothering anything on either side. Nothing to
do with hardware registers. The structure could be out of a file,
off the network, or read from any device. O'caml programmers obviously
don't spend much time thinking about binary compatibility of data
transfer to other machines.
Oh yeah, I remember... file I/O is not a "functional" concept.
- Tel
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)
iQIVAwUBQzxpwMfOVl0KFTApAQI9BQ/+P05WcQJ3cTvSCkBGh93LAcI23DpIkgTc
DZbCCs7h9Y0G2KChma49SsGz5a+AakXD324+i10u0MiSWaJC3sR3hpnZigNAMZqL
UG85bgKXIc13DnWgsUaT9Ioaef7w1pAcqNTEU2RjoSw1TDSlE5KyxHP7Ko0RsKla
9A/VElDWt8uVo+eXP5rqSLNdaFi5QpkmgQRkWvsNlbBlghx8Rqz/DDMFt90IDg7W
5Y7ltyq8FEX+q9/TtJe9axl40fwofo+JykvEJhz4KGAW1/jNiGugwD/UBU92oOo6
CDbU4kXrfDTBqKR8ggUFbGH6C/dFuXSW3CW/UNzBxTmw8MY+ezrDDTsmB4XM+PY3
2bDdpDEWgihBPiwW/dMfCw1bZXjkkjAoPTAKYCwdS/uYg9TcPfF4tpylTisMLPnL
5YQw/87GPmO+5HyX0nlP8egVPqYoIFPfc/89NasqlHh8nIAashyOz1xUPWgHuleN
Qg88nPwiY/u2u0FoUPoRQlAM5cQQ3w2GOXIqQKtw3MFQee5pEw3UvDpQwrdwYblO
FAr9bM/Q76PAtykwJaMBUh7lnqWizrbJAVOtEdu7tr8NZbX9AytO36udL18M3DDa
him+hOy0z/QOiz16UUXuS5pYUk+lX1gCj8grsqoiYyKwMM5RuW0SxDZOoEEn8kLM
UOXOupu/zv4=
=ZpjW
-----END PGP SIGNATURE-----
--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html