Compiler Specific Operators

peters at cubsvax.UUCP peters at cubsvax.UUCP
Fri Jul 18 00:02:04 AEST 1986


In article <petrus.224> purtill at petrus.UUCP (Mark Purtill) writes:
[re: reasons for not permitting a compiler to expand "function calls" in-line]

>Ever heard of debugging?  You might well want to set a trap at that
>function, or even replace it with a different version that is somehow
>useful, such as a version that prints out its arguments.

If you want to set a trap, in-line expansion is no worse than having to deal
with anything else in your code that doesn't call a function.

If you want to replace the built-in function with a new version, either use a 
new name in-line, or else write a #define to a new name.

Since most people don't have source code to the math library anyway, both 
of your suggestions would seem to be more useful for debugging the compiler or
math library than for debugging user code that invokes them.  Assuming one has
a compiler that works, these features would seem to be of little use to the
USER, as opposed to the compiler-writer.  And I don't care about the compiler-
writer!

But I'd still like to hear someone on the committee confirm that this
is disallowed (if, in fact, it is!), and comment on what went into the 
committee's decision to disallow it.

Peter S. Shenkin	 Columbia Univ. Biology Dept., NY, NY  10027
{philabs,rna}!cubsvax!peters		cubsvax!peters at columbia.ARPA



More information about the Comp.lang.c mailing list