[svn:parrot] r44904 - branches/ops_pct/compilers/opsc/src/Ops/Compiler
bacek at svn.parrot.org
bacek at svn.parrot.org
Fri Mar 12 22:13:39 UTC 2010
Author: bacek
Date: Fri Mar 12 22:13:36 2010
New Revision: 44904
URL: https://trac.parrot.org/parrot/changeset/44904
Log:
Add bit of information how op_macro _will_ be handled.
Modified:
branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm
Modified: branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm
==============================================================================
--- branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm Fri Mar 12 21:48:22 2010 (r44903)
+++ branches/ops_pct/compilers/opsc/src/Ops/Compiler/Actions.pm Fri Mar 12 22:13:36 2010 (r44904)
@@ -326,6 +326,17 @@
method op_macro($/) {
#say('# op_macro');
+ # Generate set of calls to Trans:
+ # goto NEXT() -> goto_offset(opsize())
+ # goto OFFSET($addr) -> goto_offset($addr)
+ # goto ADDRESS($addr) -> goto_address($addr)
+ # expr NEXT() -> expr_offset(opsize())
+ # expr OFFSET($addr) -> expr_offset($addr)
+ # expr ADDRERR($addr) -> expr_address($addr)
+ # restart NEXT() -> restart_offset(opsize()); goto_offset(opsize())
+ # restart OFFSET() -> restart_offset($addr); goto_offset($addr)
+ # restart ADDRESS() -> restart_address($addr); goto_offset($addr)
+
my $is_next := ~$<macro_destination> eq 'NEXT';
my $macro_name := ~$<macro_type> ~ '_' ~ lc($is_next ?? 'offset' !! ~$<macro_destination>);
More information about the parrot-commits
mailing list