https://github.com/jrincayc/ucblogo-code
Raw File
Tip revision: 62fc2f7d6c41edcf685277a872c68e47a76fb254 authored by Dan Malec on 12 December 2020, 01:50:52 UTC
FEAT-CD: Initial pass at having a CD build.
Tip revision: 62fc2f7
macroexpand
MACROEXPAND expr					(library procedure)

	takes as its input a Logo expression that invokes a macro (that is,
	one that begins with the name of a macro) and outputs the the Logo
	expression into which the macro would translate the input expression.


		.macro localmake :name :value
		op `[local ,[word "" :name] apply "make [,[:name] ,[:value]]]
		end

		? show macroexpand [localmake "pi 3.14159]
		[local "pi apply "make [pi 3.14159]]


back to top