Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!edg1!jsa From: jsa@edg1.UUCP (J. Stephen Adamczyk) Newsgroups: comp.std.c Subject: Function type compatibility and the ellipsis Message-ID: <947@edg1.UUCP> Date: 9 Feb 91 01:26:51 GMT Organization: Edison Design Group Inc., Upper Montclair, NJ Lines: 21 Is the following program legal? int f(int a, ...); int f(a) int a; { return 0; } The rules for function type compatibility in 3.5.4.3 say that "If one type has a parameter type list and the other type is specified by a function definition that contains a (possibly empty) identifier list, both shall agree in the number of parameters, and the type of each prototype parameter shall be compatible with the type that results from the application of the default argument promotions to the type of the corresponding identifier." Note that of the three cases discussed in the paragraph, only this one fails to mention an ellipsis compatibility requirement. An oversight? An intentional omission? Steve Adamczyk (jsa@edg.com or uunet!edg1!jsa; 201-744-2620)