Actual source code: knr-compat.h

      1: #ifndef KNR_COMPAT_H
      2: #define KNR_COMPAT_H 1

      4: /* ALWAYS use prototypes */
      5: #define USE_PROTOTYPES 1
      6: #define USE_FN_ARGS 1

      8: #ifdef USE_PROTOTYPES
      9: #define Proto(x) x
     10: #else
     11: #define Proto(x) ()
     12: #endif

     14: #ifdef USE_FN_ARGS

     16: #define ARG0(x) (void)
     17: #define ARG1(type1,var1) (type1 var1)
     18: #define ARG2(type1,var1,type2,var2) (type1 var1,type2 var2)
     19: #define ARG3(type1,var1,type2,var2,type3,var3) (type1 var1,type2 var2,type3 var3)
     20: #define ARG4(type1,var1,type2,var2,type3,var3,type4,var4) (type1 var1,type2 var2,type3 var3,type4 var4)
     21: #define ARG5(type1,var1,type2,var2,type3,var3,type4,var4,type5,var5) (type1 var1,type2 var2,type3 var3,type4 var4,type5 var5)

     23: #else /* Use K&R style */

     25: #define ARG0(x) ()
     26: #define ARG1(type1,var1) (var1) type1 var1;
     27: #define ARG2(type1,var1,type2,var2) (var1,var2) type1 var1; type2 var2;
     28: #define ARG3(type1,var1,type2,var2,type3,var3) (var1,var2,var3) type1 var1; type2 var2; type3 var3;
     29: #define ARG4(type1,var1,type2,var2,type3,var3,type4,var4) (var1,var2,var3,var4) type1 var1; type2 var2; type3 var3; type4 var4;
     30: #define ARG5(type1,var1,type2,var2,type3,var3,type4,var4,type5,var5) (var1,var2,var3,var4,var5) type1 var1; type2 var2; type3 var3; type4 var4; type5 var5;
     31: #endif /* K&R Decls */

     33: #endif /* KNR_COMPAT_H */