Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Ben Pfaff <blp@cs.stanford.edu> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: Question |
| Date | 2011-06-08 13:54 -0700 |
| Message-ID | <87pqmokpr9.fsf@blp.benpfaff.org> (permalink) |
| References | <cbbad7e4-3532-4062-b39e-e4ad92a34f9d@p13g2000yqh.googlegroups.com> <8739jkmdin.fsf@blp.benpfaff.org> <e2ce4af8-9fb7-459c-88f6-58764f24f6b8@g12g2000yqd.googlegroups.com> <op.vwryxstt5qv6o3@toshiba-laptop> |
"Morris Keesan" <mkeesan@post.harvard.edu> writes:
> int i = -1;
> long int l = i;
>
> assert(sizeof(long) > sizeof(int));
> printf("%ld\n", l);
What is the value of the assertion? Every signed type is capable
of holding -1.
--
Ben Pfaff
http://benpfaff.org
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Question Mateusz_madi <madi.czadi@gmail.com> - 2011-06-08 10:31 -0700
Re: Question Ben Pfaff <blp@cs.stanford.edu> - 2011-06-08 10:36 -0700
Re: Question Mateusz_madi <madi.czadi@gmail.com> - 2011-06-08 10:49 -0700
Re: Question Ben Pfaff <blp@cs.stanford.edu> - 2011-06-08 10:54 -0700
Re: Question Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2011-06-08 12:49 -0600
Re: Question Keith Thompson <kst-u@mib.org> - 2011-06-08 11:55 -0700
Re: Question Ben Pfaff <blp@cs.stanford.edu> - 2011-06-08 12:21 -0700
Re: Question "Kleuskes & Moos" <kleuske@xs4all.nl> - 2011-06-08 16:02 -0700
Re: Question Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2011-06-08 17:31 -0600
Re: Question Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2011-06-08 17:30 -0600
Re: Question Peter Nilsson <airia@acay.com.au> - 2011-06-08 16:34 -0700
Re: Question "Morris Keesan" <mkeesan@post.harvard.edu> - 2011-06-08 16:52 -0400
Re: Question Ben Pfaff <blp@cs.stanford.edu> - 2011-06-08 13:54 -0700
Re: Question "J. J. Farrell" <jjf@bcs.org.uk> - 2011-06-09 03:22 +0100
Re: Question Keith Thompson <kst-u@mib.org> - 2011-06-08 10:47 -0700
csiph-web