[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Two functions for everything?



    From: DCP@QUABBIN.SCRC.Symbolics.COM (David C. Plummer)

    This is bogus folks.  All you need is two entrypoints: one which doesn't
    check anything, and one which checks what it needs to.  They then join.
    Safety 0 (at compile time) causes functions to call the the
    don't-check-anything entrypoint, and safety > 0 causes functions to call
    the one that checks.  Hell, you could have a different entrypoint for
    each setting of safety.

Yeah, but where in CLtL do we provide a way to make functions with multiple
entry points?  I certainly don't want to have to hand-code every single
function that does optional error checking in assembly language (or
whatever).  The point I was trying to make was that, if we are serious
about making multiple levels of error checking part of the language, we
should also provide some high-level constructs for specifying what error
checking goes on when.  Multiple entry points would be one way to implement
such a construct....

-Sandra

-------