[Gd-chatter] [Bug 7369] New: Gwydion Dylan semicolon-separated macro patterns

bugzilla-daemon at gwydiondylan.org bugzilla-daemon at gwydiondylan.org
Fri Feb 15 03:48:14 CET 2008


http://www.gwydiondylan.org/cgi-bin/bugzilla/show_bug.cgi?id=7369

           Summary: Gwydion Dylan semicolon-separated macro patterns
           Product: compiler
           Version: unspecified
          Platform: Macintosh
        OS/Version: Mac OS
            Status: NEW
          Severity: normal
          Priority: P2
         Component: parser
        AssignedTo: andreas at andreas.org
        ReportedBy: d_j_v at mac.com
                CC: gd-chatter at gwydiondylan.org


The following does not compile:

----------
module: testapp

define macro tokenizer-definer
   {
      define tokenizer ?token-name:name
         rule ?rule:expression => ?product-name:name;
         yield ?:expression;
      end
   } => {
      format-out("matches\n")
   }
end macro;

define tokenizer markup-block
   rule 3 + 3 => val;
   yield val;
end;

define function main()
   let vals = apply(identity, "a");
   format-out("%=\n", vals)
end function;

main()
----------

If the semi-colon is removed from the end of the "yield" pattern and from the
macro call, it compiles. If the semi-colons are changed to commas, it compiles.

This seems like a violation of the DRM macro-parsing rules. You should be able
to omit or include the final semi-colon in the macro call.


-- 
Configure bugmail: http://www.gwydiondylan.org/cgi-bin/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.



More information about the chatter mailing list