[svn:parrot] r46398 - branches/ops_pct/compilers/opsc

cotto at svn.parrot.org cotto at svn.parrot.org
Sat May 8 01:36:42 UTC 2010


Author: cotto
Date: Sat May  8 01:36:41 2010
New Revision: 46398
URL: https://trac.parrot.org/parrot/changeset/46398

Log:
[opsc] simplify opsc.pir, remove an obsolete todo item

Modified:
   branches/ops_pct/compilers/opsc/TODO
   branches/ops_pct/compilers/opsc/opsc.pir

Modified: branches/ops_pct/compilers/opsc/TODO
==============================================================================
--- branches/ops_pct/compilers/opsc/TODO	Sat May  8 00:26:09 2010	(r46397)
+++ branches/ops_pct/compilers/opsc/TODO	Sat May  8 01:36:41 2010	(r46398)
@@ -6,7 +6,6 @@
 
 Required for full implementation:
   * A LOT OF DOCUMENTATION.
-  * Implement Trans::* for other runcores.
   * Implement handling of dynops.
   * Add tests for Trans::C independent from 06-emitter.t
   * Add tests for dynamic mode of Emitter.

Modified: branches/ops_pct/compilers/opsc/opsc.pir
==============================================================================
--- branches/ops_pct/compilers/opsc/opsc.pir	Sat May  8 00:26:09 2010	(r46397)
+++ branches/ops_pct/compilers/opsc/opsc.pir	Sat May  8 01:36:41 2010	(r46398)
@@ -4,11 +4,6 @@
 
 .namespace [ 'Ops';'Compiler' ]
 
-.loadlib 'P6object.pbc'
-.loadlib 'HLL.pbc'
-.loadlib 'PCT.pbc'
-.loadlib 'nqp-settings.pbc'
-
 .include 'compilers/opsc/src/builtins.pir'
 .include 'compilers/opsc/gen/Ops/Compiler/Grammar.pir'
 .include 'compilers/opsc/gen/Ops/Compiler/Actions.pir'
@@ -22,49 +17,6 @@
 .include 'compilers/opsc/gen/Ops/OpLib.pir'
 .include 'compilers/opsc/gen/Ops/File.pir'
 
-.sub 'main' :main
-    .param pmc args
-    $P0 = compreg 'Ops'
-    $P1 = $P0.'command_line'(args, 'encoding'=>'utf8', 'transcode'=>'ascii')
-.end
-
-.sub 'onload' :load :init
-    # Register grammar and action
-    $P0 = new [ 'Ops';'Compiler' ]
-
-    #these stages aren't currently used, although generate_files exits before
-    #they can be called anyway
-    $P0.'removestage'('post')
-    $P0.'removestage'('pir')
-    $P0.'removestage'('evalpmc')
-    $P0.'addstage'('generate_runcores', 'after'=>'past')
-.end
-
-.sub 'generate_runcores' :method
-    .param pmc past
-    .param pmc adverbs :slurpy :named
-
-    .local pmc oplib, files
-
-    $P0 = find_caller_lex "$?FILES"
-    $S0 = $P0
-    files = split " ", $S0
-    #do oplib stuff
-    # - make an oplib
-    $P0 = get_hll_global ['Ops'], 'OpLib'
-    oplib = $P0.'new'()
-    #use default location for ops.num and ops.skip for now
-    oplib.'BUILD'(files :named("files"))
-    oplib.'set_ops_past'(past)
-    oplib.'build_ops'()
-
-    #for each runcore
-    # * make a clone of the op tree
-    # * call the runcore with it
-
-    exit 0
-.end
-
 # Local Variables:
 #   mode: pir
 #   fill-column: 100


More information about the parrot-commits mailing list