<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Why asterisk comments working in MACRO? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913308#M359985</link>
    <description>&lt;P&gt;Looks like it worked to me.&amp;nbsp; Make sure to turn on MPRINT so you can see the statement comments that you are generating.&lt;/P&gt;
&lt;PRE&gt;1    %macro abc;
2      *%put #1#@ In abc;
3    %mend;
4
5
6
7    %macro doit;
8      *%abc
9      %put #2#@ Here;
10     *%let x=%abc;
11     %put #2#@ &amp;amp;=x;
12   %mend;
13
14
15   options mprint;
16   %doit;
#2#@ Here
MPRINT(DOIT):   *%abc
#1#@ In abc
#2#@ X=*
MPRINT():   *
17   ;;;;
&lt;/PRE&gt;
&lt;P&gt;But it really does not make much sense to put in a statement comment that does not actually include any comment text.&amp;nbsp; And even worse to put in one that does not have an ending semicolon.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let's examine your ABC macro.&amp;nbsp; The first and last lines just define the start and end of the macro definition.&amp;nbsp; The middle line starts a comment.&amp;nbsp; Then it has a complete macro statement (%put statement.) but it never ends the comment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So when you call that macro whatever text you have following the macro up to the next semicolon will become the text of the comment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So this example usage of %ABC&lt;/P&gt;
&lt;PRE&gt;18   %macro doit();
19   data _null_;
20     %abc
21     set sashelp.class;
22   run;
23   %mend;
24
25   options mprint;
26   %doit()
MPRINT(DOIT):   data _null_;
#1#@ In abc
MPRINT(ABC):   *
MPRINT(DOIT):   set sashelp.class;
MPRINT(DOIT):   run;
NOTE: DATA statement used (Total process time):
      real time           0.02 seconds
      cpu time            0.03 seconds&lt;/PRE&gt;
&lt;P&gt;caused the %DOIT macro to generate three statements. A DATA and a RUN statement with a comment statement in the middle.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That missing semicolon is that is causing the MPRINT lines to look so strange in your original example.&amp;nbsp; If we include the semicolon into the definition of ABC then it looks better.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want your macro to emit statement comments you should take care to include the ending semicolon in the macro definition.&lt;/P&gt;
&lt;P&gt;For example like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%macro print(data);
* This macro prints a dataset ;
proc print data=&amp;amp;data;
run;
* This is the last statement generated by the macro ;
%mend print;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;So if you run that macro (with MPRINT on) you get this in the SAS log.&lt;/P&gt;
&lt;PRE&gt;48   %print(sashelp.class)
MPRINT(PRINT):   * This macro prints a dataset ;
NOTE: Writing HTML Body file: sashtml.htm
MPRINT(PRINT):   proc print data=sashelp.class;
MPRINT(PRINT):   run;

NOTE: There were 19 observations read from the data set SASHELP.CLASS.
NOTE: PROCEDURE PRINT used (Total process time):
      real time           1.55 seconds
      cpu time            1.03 seconds


MPRINT(PRINT):   * This is the last statement generated by the macro ;

&lt;/PRE&gt;
&lt;P&gt;If you want to comment out macro code then either using BLOCK comments /* ... */.&lt;/P&gt;
&lt;P&gt;Or use a MACRO comment %* .... ;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 29 Jan 2024 04:27:49 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2024-01-29T04:27:49Z</dc:date>
    <item>
      <title>Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913285#M359973</link>
      <description>&lt;P&gt;I got this from Carpenter's book (Complete Guide to the SAS Macro language):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%macro abc;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; *%put #1#@ In abc;&lt;BR /&gt;%mend;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%macro doit;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; *%abc&lt;BR /&gt;&amp;nbsp; &amp;nbsp; %put #2#@ Here;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; *%let x=%abc;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; %put #2#@ &amp;amp;=x;&lt;BR /&gt;%mend;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;%doit;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I assumed * will not work inside of a macro, but got results as here:&lt;/P&gt;&lt;P&gt;#2#@ Here&lt;BR /&gt;#1#@ In abc&lt;BR /&gt;#2#@ X=*&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This indicates that the * does comment out %abc.&amp;nbsp; Why?&lt;/P&gt;</description>
      <pubDate>Sun, 28 Jan 2024 22:47:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913285#M359973</guid>
      <dc:creator>jason4sas</dc:creator>
      <dc:date>2024-01-28T22:47:02Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913294#M359977</link>
      <description>&lt;P&gt;The &lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lestmtsglobal/n1v51exifva71an1cvfn2z6j26lo.htm" target="_self"&gt;documentation&lt;/A&gt; is clear.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Patrick_1-1706487278523.png" style="width: 1029px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/93028i21E1EEBB190B8A53/image-dimensions/1029x214?v=v2" width="1029" height="214" role="button" title="Patrick_1-1706487278523.png" alt="Patrick_1-1706487278523.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your sample code the %put statement from macro %abc gets written to the log so macro %abc gets executed as well as the %put statement within the macro&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Patrick_2-1706487355355.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/93029iD9D6C98F6BCA3F89/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Patrick_2-1706487355355.png" alt="Patrick_2-1706487355355.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your code the comment doesn't get ended with a semicolon on the same line.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Patrick_3-1706487460265.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/93030iD07FFAFD84B6C59D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Patrick_3-1706487460265.png" alt="Patrick_3-1706487460265.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;But still the macro executes. The timing is a bit weird like why does this %put statement then only write to the 2nd line in the code - but given you use a comment syntax that's not supported for the macro language unexpected results are always possible.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 00:20:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913294#M359977</guid>
      <dc:creator>Patrick</dc:creator>
      <dc:date>2024-01-29T00:20:43Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913302#M359981</link>
      <description>&lt;P&gt;I think you should use “%*” , not "*%" 。&lt;/P&gt;
&lt;P&gt;Both "%*" and "/* */" could comment out the code in MACRO , not "*%" .&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Ksharp_0-1706493806784.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/93032i735551184D55D184/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Ksharp_0-1706493806784.png" alt="Ksharp_0-1706493806784.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 02:03:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913302#M359981</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2024-01-29T02:03:53Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913308#M359985</link>
      <description>&lt;P&gt;Looks like it worked to me.&amp;nbsp; Make sure to turn on MPRINT so you can see the statement comments that you are generating.&lt;/P&gt;
&lt;PRE&gt;1    %macro abc;
2      *%put #1#@ In abc;
3    %mend;
4
5
6
7    %macro doit;
8      *%abc
9      %put #2#@ Here;
10     *%let x=%abc;
11     %put #2#@ &amp;amp;=x;
12   %mend;
13
14
15   options mprint;
16   %doit;
#2#@ Here
MPRINT(DOIT):   *%abc
#1#@ In abc
#2#@ X=*
MPRINT():   *
17   ;;;;
&lt;/PRE&gt;
&lt;P&gt;But it really does not make much sense to put in a statement comment that does not actually include any comment text.&amp;nbsp; And even worse to put in one that does not have an ending semicolon.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Let's examine your ABC macro.&amp;nbsp; The first and last lines just define the start and end of the macro definition.&amp;nbsp; The middle line starts a comment.&amp;nbsp; Then it has a complete macro statement (%put statement.) but it never ends the comment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So when you call that macro whatever text you have following the macro up to the next semicolon will become the text of the comment.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So this example usage of %ABC&lt;/P&gt;
&lt;PRE&gt;18   %macro doit();
19   data _null_;
20     %abc
21     set sashelp.class;
22   run;
23   %mend;
24
25   options mprint;
26   %doit()
MPRINT(DOIT):   data _null_;
#1#@ In abc
MPRINT(ABC):   *
MPRINT(DOIT):   set sashelp.class;
MPRINT(DOIT):   run;
NOTE: DATA statement used (Total process time):
      real time           0.02 seconds
      cpu time            0.03 seconds&lt;/PRE&gt;
&lt;P&gt;caused the %DOIT macro to generate three statements. A DATA and a RUN statement with a comment statement in the middle.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That missing semicolon is that is causing the MPRINT lines to look so strange in your original example.&amp;nbsp; If we include the semicolon into the definition of ABC then it looks better.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want your macro to emit statement comments you should take care to include the ending semicolon in the macro definition.&lt;/P&gt;
&lt;P&gt;For example like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%macro print(data);
* This macro prints a dataset ;
proc print data=&amp;amp;data;
run;
* This is the last statement generated by the macro ;
%mend print;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;So if you run that macro (with MPRINT on) you get this in the SAS log.&lt;/P&gt;
&lt;PRE&gt;48   %print(sashelp.class)
MPRINT(PRINT):   * This macro prints a dataset ;
NOTE: Writing HTML Body file: sashtml.htm
MPRINT(PRINT):   proc print data=sashelp.class;
MPRINT(PRINT):   run;

NOTE: There were 19 observations read from the data set SASHELP.CLASS.
NOTE: PROCEDURE PRINT used (Total process time):
      real time           1.55 seconds
      cpu time            1.03 seconds


MPRINT(PRINT):   * This is the last statement generated by the macro ;

&lt;/PRE&gt;
&lt;P&gt;If you want to comment out macro code then either using BLOCK comments /* ... */.&lt;/P&gt;
&lt;P&gt;Or use a MACRO comment %* .... ;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 04:27:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913308#M359985</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2024-01-29T04:27:49Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913386#M360023</link>
      <description>&lt;P&gt;Thanks for the help. I am trying to understand why * before %abc does block the execution of the macro, whereas it does not in&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;*%let x=%abc;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;I am not sure if ";" plays any role after *%abc since it does not change the result at all.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 13:11:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913386#M360023</guid>
      <dc:creator>jason4sas</dc:creator>
      <dc:date>2024-01-29T13:11:30Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913389#M360025</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/251325"&gt;@jason4sas&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Thanks for the help. I am trying to understand why * before %abc does block the execution of the macro, whereas it does not in&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;*%let x=%abc;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;I am not sure if ";" plays any role after *%abc since it does not change the result at all.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Are you sure it did not work?&amp;nbsp; It is very hard to tell when the only SAS code the macro logic is generating are * characters and semicolons.&amp;nbsp; And it is doubly confusing when the macro calls do NOT supply the closing semicolon for the last SAS statement they generate.&amp;nbsp; The effect is that when the statement does finally get finished it ends up running after the macro has finished.&amp;nbsp; Again it is very hard to see these effect completely when the only SAS code the macro logic is generating are comment statements, since by definition a comment statement does not have any real effect.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;That line you showed is trying to start a statement comment.&amp;nbsp; Then it runs a macro statement, %LET.&amp;nbsp; Since the call to %ABC is going to generate another * you should get an * into the macro variable X.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 13:29:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913389#M360025</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2024-01-29T13:29:16Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913390#M360026</link>
      <description>&lt;P&gt;Thanks Tom's mprint, I might have got the reason: *%abc does not contain macro statements, so it was put in the word queue where the statement is regarded as SAS statement and * does work then to comment out %abc. However, %let is a standard macro statement so it got executed immediately. Please straighten me out if it still is not much correct.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 13:33:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913390#M360026</guid>
      <dc:creator>jason4sas</dc:creator>
      <dc:date>2024-01-29T13:33:10Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913401#M360030</link>
      <description>&lt;P&gt;I think you have it.&lt;/P&gt;
&lt;P&gt;You can seem something similar with just macro variable resolution.&lt;/P&gt;
&lt;PRE&gt;1    %macro test(parm1);
2    %put NOTE: &amp;amp;sysmacroname: &amp;amp;=parm1 ;
3    * The value of PARM1 is &amp;amp;parm1 ;
4    %put The value of PARM1 is &amp;amp;parm1 ;
5    %mend test;
6
7    %test(xxx)
MLOGIC(TEST):  Beginning execution.
MLOGIC(TEST):  Parameter PARM1 has value xxx
MLOGIC(TEST):  %PUT NOTE: &amp;amp;sysmacroname: &amp;amp;=parm1
NOTE: TEST: PARM1=xxx
MPRINT(TEST):   * The value of PARM1 is &amp;amp;parm1 ;
MLOGIC(TEST):  %PUT The value of PARM1 is &amp;amp;parm1
The value of PARM1 is xxx
MLOGIC(TEST):  Ending execution.
&lt;/PRE&gt;</description>
      <pubDate>Mon, 29 Jan 2024 14:17:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913401#M360030</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2024-01-29T14:17:10Z</dc:date>
    </item>
    <item>
      <title>Re: Why asterisk comments working in MACRO?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913403#M360031</link>
      <description>&lt;P&gt;I'm also surprised that a&amp;nbsp; * comment in a macro definition can comment out a macro invocation:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;options mlogic ;
%macro abc();
  %put I do not execute ;
%mend;

%macro doit() ;
  * %abc() ;
%mend;

%doit()&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;I think you're right that officially a macro invocation is not a macro language statement.&amp;nbsp; So perhaps this behavior is undefined by the documentation.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But I don't think the macro call should go to the word queue.&amp;nbsp; I would expect when the above macro executes the * would go to the word queue, the macro call %abc would execute, and then the semicolon would go to the word queue.&amp;nbsp; But obviously that's not what happens.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;My guess is it has something to do with the macro language compiler.&amp;nbsp; Clearly when the macro is compiled, the compiler is looking inside of * comments.&amp;nbsp; This is because the * has no meaning to the macro compiler.&amp;nbsp; And it is why macro statements inside of a * comment will be compiled (and later executed).&amp;nbsp; I suppose it's possible that a macro invocation is not compiled in the same way as a macro statement is compiled.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Okay, here's another oddity.&amp;nbsp; With this code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;options mlogic ;
%macro abc();
   Hello world
%mend;

%macro doit() ;
  * %abc() ;
%mend;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If I code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%doit()&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;the macro ABC is not invoked.&amp;nbsp; But if I code:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%put %doit() ;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;the macro ABC is invoked.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So I'm not sure what to conclude, except that the * is not a comment in the macro language, and when you use * comments inside a macro definition, behavior can be odd.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm away from my bookcase.&amp;nbsp; Does Art not explain this behavior?&lt;/P&gt;</description>
      <pubDate>Mon, 29 Jan 2024 14:19:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Why-asterisk-comments-working-in-MACRO/m-p/913403#M360031</guid>
      <dc:creator>Quentin</dc:creator>
      <dc:date>2024-01-29T14:19:38Z</dc:date>
    </item>
  </channel>
</rss>

