This is the mail archive of the cgen@sourceware.org mailing list for the CGEN project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[commit] Implement %-prefixed pmacros.


Hi.

This patch implements %-prefixed pmacros.
Support for .-prefixed pmacros will eventually go away,
but obviously all the .cpu files will need to be changed first.

To migrate, add (define-rtl-version 0 9) to the front of your .cpu file.

[For reference, a reminder why I'm doing this:
"." is not a valid first character in r6rs symbols.]

2010-01-28  Doug Evans  <dje@sebabeach.org>

	* pmacros.scm (pmacros-init!): New arg rtl-version, all callers
	updated.  Use %-prefix if rtl-version >= 0.9.
	* read.scm (/supported-rtl-versions): Add (0 9).
	(/rtl-version-valid?): New function.
	(/cmd-define-rtl-version): If new rtl version, reinvoke pmacros-init!.
	(/reader-expr): New function.
	(reader-process): New function.
	(/reader-process-with-loc!): Renamed from /reader-process!.
	Don't pre-expand `if' commands.
	(/cmd-if): Simplify.  Pmacro-expand test, then, else clauses here.
	Handle rtl-version-equal?, rtl-version-at-least?.
	* testsuite/Makefile.am (clean-test-files): Remove *.test.cpu*.
	* testsuite/Makefile.in: Regenerate.
	* testsuite/pmacros-1.test: Test both . and % as prefixes.
	* testsuite/testsuite.cpu (/begin, /print, /dump): New pmacros.
	(newline, print-match, print-expr, print-thunk): Use them.
	(internal-verify): Update definition.
	* doc/rtl.texi (define-rtl-version): Document rtl version 0.9.
	(Top level conditionals): New node.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]