Re: Idea for 'documenting' unused values
- Posted by Derek Parnell <ddparnell at bigpond.com> Jul 24, 2004
- 496 views
irv mullins wrote: > > Mike Nelson wrote: > > > > Derek's idea of an ignore() procedure is excellent in terms of being > > self-documenting. If it were implemented in the interpreter, the overhead of > > the procedure call could be optimized away, just as is done for then > > platform() function. > > Perhaps I misunderstand the problem, but isn't this about unused parameters > (which must nevertheless be included as placeholders) causing warnings? No. It is *also* about unused function return values, not just unused parameters. > If that is the case, then Euphoria should provide a dummy type to be used > as a placeholder, one which wouldn't generate the warning. Should be > easy to implement. I guess you mean something like ... procedure Click_Button(integer self, ignore, ignore) . . . end procedure This is a nice idea too. We could expand it to something similar for function returns... void = FuncA() -- Derek Parnell Melbourne, Australia