目的是这样的,要删除已经存在的宏变量,之所以使用宏是为了批量删除方便;
在此仅以一个宏变量age为例,但是运行后报错:
ERROR: Macro variable name & must start with a letter or underscore.
觉得问题出在%symdel这个语句对宏变量的解析上,试过多种方法包括改写做%symdel "&var";
变量倒是解析了,但同样报错:
ERROR: Macro variable name "AGE" must start with a letter or underscore.
%liu(age)
;
%put &age; %*won't be resolved;[/code:8yuohn84]
I cannot replicate exactly the same error message as yours, but I don't see any mistakes from your original code.
On the other hand, I guess, that error could be due to an earlier-than-expected resolved macro varible.
[quote:8yuohn84]ERROR: Macro variable name & must start with a letter or underscore.[/quote:8yuohn84]
I guess that was from %symdel & var; %*unnecessary blank space between;
[quote:8yuohn84]%symdel "&var";
ERROR: Macro variable name "AGE" must start with a letter or underscore.[/quote:8yuohn84]
This is clear here %symdel "&var"--->%symdel "Age" ---> incorrect nomination for a macro variable.
*****JingJu*****作者: shiyiming 时间: 2010-1-18 12:59 标题: Re: 请教%symdel的用法 Thank you! But there is a WARNING: Apparent invocation of macro SYMEXIST not resolved.
I thought the reason may be the version. My system was 8.2.