Re: Inform: How to make a function optional?


Wed, 22 Nov 1995 12:15:03 -0500

"Sam Hulick" <shulick@kiwi.ucs.indiana.edu> writes:
> I simply want CreditRoutine() to be optional. If it is defined, then
> call it. if it's not defined, don't call it. How can I do this? I
> figured #Stub was the answer to this. Do I just do an #IFDEF
> CreditRoutine?

Like I said, #Stub must come after the definition of the actual
routine, or you get an error. Put #Stub at the end of your file.

But I think that, within a single program (as opposed to a library),
this is potentially confusing. I'd just put #ifdefs around the
contents of CreditRoutine.

--Z

"And Aholibamah bare Jeush, and Jaalam, and Korah: these were the borogoves..."