home *** CD-ROM | disk | FTP | other *** search
- Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU
- Path: sparky!uunet!paladin.american.edu!auvm!UZ.KULEUVEN.AC.BE!JORRIT
- Message-ID: <9301260732.AA02132@malpighi.uz.kuleuven.ac.be>
- Newsgroups: bit.listserv.i-amiga
- Date: Tue, 26 Jan 1993 08:38:58 +0100
- Sender: Info-Amiga List <I-AMIGA@RUTVM1.BITNET>
- From: jorrit@UZ.KULEUVEN.AC.BE
- Subject: Re: C Compilers
- Lines: 28
-
- >Does anyone have recommendations on GCC or DICE?
-
- GCC is very good (generates magnificent code and is very useful to port
- Unix programs) but you need a lot of memory and harddisk space (4 megabyte
- memory is about the minimum I think). GCC is actually three compilers in
- one: normal Ansi C with many many GNU extensions, a extensive C++ compiler
- and an Objective C compiler.
-
- If you're only concerned about portability to other GCC compilers on other
- platforms you can use some of the nice extra C features. Here are some
- examples:
-
- - A 'long long' type for 64 bit integers.
- - You can use constructions like (a > b ? c : d) = 3; which assigns 3 to
- 'c' if a > b or 3 to 'd' otherwise.
- - A new 'typeof' command to get the type of an identifier. For example:
- int a;
- typeof (a) b;
- This can be very useful in macros (if you want to write a general and safe MAX
- macro for example)
- - You can also use {} in expressions, allowing things like:
- a={int b,i; for (b=i=0;i<4;i++) b += i; b}+4;
- - And a lot more I don't remember
-
- -----------------------------------------------------------------------------
- Jorrit Tyberghein : author of PowerVisor
- jorrit@uz.kuleuven.ac.be
- -----------------------------------------------------------------------------
-