DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

(standards.info) Using Extensions

Info Catalog (standards.info) Compatibility (standards.info) Design Advice (standards.info) ANSI C
 
 Using Non-standard Features
 ===========================
 
    Many GNU facilities that already exist support a number of convenient
 extensions over the comparable Unix facilities.  Whether to use these
 extensions in implementing your program is a difficult question.
 
    On the one hand, using the extensions can make a cleaner program.
 On the other hand, people will not be able to build the program unless
 the other GNU tools are available.  This might cause the program to
 work on fewer kinds of machines.
 
    With some extensions, it might be easy to provide both alternatives.
 For example, you can define functions with a "keyword" `INLINE' and
 define that as a macro to expand into either `inline' or nothing,
 depending on the compiler.
 
    In general, perhaps it is best not to use the extensions if you can
 straightforwardly do without them, but to use the extensions if they
 are a big improvement.
 
    An exception to this rule are the large, established programs (such
 as Emacs) which run on a great variety of systems.  Such programs would
 be broken by use of GNU extensions.
 
    Another exception is for programs that are used as part of
 compilation: anything that must be compiled with other compilers in
 order to bootstrap the GNU compilation facilities.  If these require
 the GNU compiler, then no one can compile them without having them
 installed already.  That would be no good.
 
Info Catalog (standards.info) Compatibility (standards.info) Design Advice (standards.info) ANSI C
automatically generated byinfo2html