Re: More than one #v(expression) in a single line of a macro

Bill Freeman <[email protected]>
Newsgroups gmane.comp.hardware.microcontrollers.gnupic
Message-ID <[email protected]>
Ben,

	I find the (f)lex stuff especially scary.

	But for your specific problem, would something like the
following work?

---------------------------------------------------------------
	list	p=16f877
	include "p16f877.inc"

inner	macro	a, b
a#v(b)	set	0x45
	endm

outer	macro	a, b
	inner	label#v(a)_, b
	endm

inner2	macro	a
a#v(j)	set	D'69'
	endm

outer2	macro
	inner2	label#v(i)_
	endm

	outer	5, 6

i	set	3
j	set	4

	outer2

	end
---------------------------------------------------------------

	This assembles for me, and if I look near the end of the .lst
file I see that both label3_5 and label5_6 have been defined properly.

							Bill
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.