Sorry, but that's different.
A macro has to generate correct code, no matter if the user of the macro chooses
to use a label on the macro call or if he or she chooses to omit the label. But
in the case of the macro definition you provided the correct function of the
generated code relies upon the fact that a label is provided - without
generating any kind of syntax error, BTW - and that is not ok.
Kind regards
Bernd
Am 21.12.2013 15:21, schrieb J.G.:
> What you and Bernd say is correct but irrelevant, indeed misconceived.
>
> o What happens if the user provides a syntactically incorrect label?
>
> o What happens if the positional parameter R1 has the value 'gubbins'?
>
> o Etc., etc.?
>
> EJ's exemplary skeletal macro and my variation on it contain no
> bulletin proofing of the [again skeletal] form
>
> |&in setb (t'&label ne 'O') --value supplied?
> | aif (&in).label_in --if so, examine it
> |&abort setb 1 --set quit switch
> | mnote . . .
> | . . .
> | ago .after_label
> |.label_in anop
> | ASYMBCHK candidate=&label, . . .
> |. . .
> |.after_label
>
> but an example of this sort, intended to illustrate a method briefly,
> is not the place for such code. We all, I must presume, know how to
> write it and do write it in our production macro definitions.
>
> J.G.
>
|