??? 06/19/09 06:56 Modified: 06/19/09 06:59 Read: times Msg Score: +1 +1 Informative |
#166242 - Portable 'C' [edited] Responding to: ???'s previous message |
Richard Erlacher said:
Consequently, it's seldom possible to write code that will compile equally effectively on a single compiler for All the PIC's, ALL the 805x's, ALL the M68HCx08's, etc. Actually, it's quite easy to write code that will compile on "all" compilers - by suitable use of typedefs, #defines, etc. In fact, it is often a very useful exercise to do so, since different compilers will often catch different subtle errors - in particular, the "larger" PC compilers will often produce far more detailed diagnostics. Having the code actually run on all the different targets is, of course, a very different matter... See: http://www.8052.com/forum/read/15762 I think Maarten Brock did a "portable" header file for Keil/SDCC/Tasking et al - but I can't seem to find it at the moment [edit] Found it: http://sdcc.svn.sourceforge.net/viewvc/sd...iew=markup [/edit] |