Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Apr 1997 12:23:28 +0800 (WST)
From:      Adrian Chadd <adrian@staff.psinet.net.au>
To:        Chuck Robey <chuckr@mat.net>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: 64 bit number definitions?
Message-ID:  <Pine.LNX.3.93.970422122139.10533A-100000@staff.psinet.net.au>
In-Reply-To: <Pine.BSF.3.91.970422001259.4630H-100000@Journey2.mat.net>

next in thread | previous in thread | raw e-mail | index | archive | help

[snip]

> 
> I've recently (for a class) been forced to code under dos, so I think I 
> know where your size guesses are coming from, but they're in error.  Run 
> the following program:
> 
> #include <stdio.h>
> #include <sys/types.h>
> 
> int main()
> {
>         int c;
>         long l;
>         quad_t q;
> 
>         printf( "sizeof int is %d, long %d, and quad %d\n",
>                 sizeof( int ), sizeof( long ), sizeof( quad_t ) );
> }
> 
> which has output "sizeof int is 4, long 4, and quad 8"

Interesting... could it be due to alignment?

Adrian.





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.3.93.970422122139.10533A-100000>