----- Original Message ----- From: Larry Bradley To: Sent: Sunday, December 01, 2002 3:44 PM Subject: Macro question > I can't figure out how to do this from reading the manual. > > I have a macro thus: (this is not real code, just to illustrate what I want > to do) > > fred macro x > anothermacro x > endm > > > Now, what I want to do is have the "othermacro" be passed the parameter > "_x", not just x. > > In other words, rather than writing > > fred _x > > > I want to write > > fred x > > and have the macro expand to > > anothermacro _x > > I can't seem to do it. > > Can you experts out there help me? > > Thanks > > > > > Larry Bradley > Orleans (Ottawa), Ontario, CANADA > This depends on the assembler. using XCASM you would write: fred .macro x anothermacro LABEL( "_" + STR(x) ) .endm I don't know how or even if you can do this in MPASM Regards Sergio Masci http://www.xcprod.com -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body