Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site decvax.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!oliveb!Glacier!decwrl!decvax!minow From: minow@decvax.UUCP (Martin Minow) Newsgroups: net.lang.c Subject: Re: One (or two) more for Guy's portability rules Message-ID: <127@decvax.UUCP> Date: Sat, 16-Nov-85 09:20:36 EST Article-I.D.: decvax.127 Posted: Sat Nov 16 09:20:36 1985 Date-Received: Tue, 19-Nov-85 03:43:14 EST References: <486@houxh.UUCP> <2600017@ccvaxa> <2883@sun.uucp> <48@hadron.UUCP> <1931@srcsip.UUCP> <2984@sun.uucp> <916@lsuc.UUCP> Reply-To: minow@decvax.UUCP (Martin minow) Organization: DEC - ULTRIX Engineering Group Lines: 20 Here are a few more guidelines (from experience -- most of my stuff has to run on two different architectures). 22. Actually port your code to at least two different architectures, operating systems, and compilers. 23. Run your code through lint wherever possible. 24. Develop a consistant method of conditionally compiling machine, system, and compiler-dependent segments. Use #if, rather than #ifdef to protect yourself against typo's (assuming your preprocessor warns you of undefined symbols in #if's). 25. Distribute a fairly large, useful, tool through mod.sources: you will soon discover that you weren't paranoid enough. 26. Run your code through lint. (Oh, for a public-domain lint!) Martin Minow decvax!minow