Author: jquelin
Date: Wed Oct 3 10:07:41 2007
New Revision: 21792
Modified:
branches/pdd15oo/examples/benchmarks/oo1.pasm
branches/pdd15oo/examples/benchmarks/oo2.pasm
branches/pdd15oo/examples/benchmarks/oo3.pasm
branches/pdd15oo/examples/benchmarks/oo4.pasm
branches/pdd15oo/examples/benchmarks/oo5.pir
branches/pdd15oo/examples/benchmarks/oo6.pir
branches/pdd15oo/examples/benchmarks/oofib.pir
branches/pdd15oo/examples/io/httpd2.pir
branches/pdd15oo/examples/pge/simple.pir
Log:
more find_type removal
Modified: branches/pdd15oo/examples/benchmarks/oo1.pasm
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oo1.pasm (original)
+++ branches/pdd15oo/examples/benchmarks/oo1.pasm Wed Oct 3 10:07:41 2007
@@ -43,14 +43,13 @@
set I10, 0
set I11, 100000
- find_type I12, "Foo"
loop:
- new P3, I12
+ P3 = new "Foo"
inc I10
#sleep 0.0001
lt I10, I11, loop
- new P3, I12
+ P3 =new "Foo"
classoffset I0, P3, "Foo"
getattribute P2, P3, I0
print P2
Modified: branches/pdd15oo/examples/benchmarks/oo2.pasm
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oo2.pasm (original)
+++ branches/pdd15oo/examples/benchmarks/oo2.pasm Wed Oct 3 10:07:41 2007
@@ -31,13 +31,12 @@
set I10, 0
set I11, 500000
- find_type I12, "Foo"
loop:
- new P3, I12
+ P3 = new "Foo"
inc I10
lt I10, I11, loop
- new P3, I12
+ P3 = new "Foo"
classoffset I0, P3, "Foo"
getattribute P2, P3, I0
print P2
Modified: branches/pdd15oo/examples/benchmarks/oo3.pasm
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oo3.pasm (original)
+++ branches/pdd15oo/examples/benchmarks/oo3.pasm Wed Oct 3 10:07:41 2007
@@ -8,8 +8,7 @@
set I10, 0
set I11, 500000
- find_type I12, "Foo"
- new P3, I12
+ P3 = new "Foo"
loop:
classoffset I0, P3, "Foo"
getattribute P2, P3, I0
Modified: branches/pdd15oo/examples/benchmarks/oo4.pasm
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oo4.pasm (original)
+++ branches/pdd15oo/examples/benchmarks/oo4.pasm Wed Oct 3 10:07:41 2007
@@ -8,8 +8,7 @@
set I10, 1
set I11, 500000
- find_type I12, "Foo"
- new P3, I12
+ P3 = new "Foo"
loop:
classoffset I0, P3, "Foo"
new P4, 'Integer'
Modified: branches/pdd15oo/examples/benchmarks/oo5.pir
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oo5.pir (original)
+++ branches/pdd15oo/examples/benchmarks/oo5.pir Wed Oct 3 10:07:41 2007
@@ -9,9 +9,8 @@
.local int typ
.local int i
i = 1
- typ = find_type "Foo"
.local pmc o
- o = new typ
+ o = new "Foo"
loop:
$P4 = o."i"()
.local pmc x
Modified: branches/pdd15oo/examples/benchmarks/oo6.pir
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oo6.pir (original)
+++ branches/pdd15oo/examples/benchmarks/oo6.pir Wed Oct 3 10:07:41 2007
@@ -9,9 +9,8 @@
.local int typ
.local int i
i = 1
- typ = find_type "Foo"
.local pmc o
- o = new typ
+ o = new "Foo"
loop:
$P4 = new 'Integer'
$P4 = i
Modified: branches/pdd15oo/examples/benchmarks/oofib.pir
==============================================================================
--- branches/pdd15oo/examples/benchmarks/oofib.pir (original)
+++ branches/pdd15oo/examples/benchmarks/oofib.pir Wed Oct 3 10:07:41 2007
@@ -21,8 +21,7 @@
A = newclass "A"
B = subclass A, "B"
- find_type $I0, "B"
- b = new $I0
+ b = new "B"
.sym pmc r
r = b."fib"(N)
Modified: branches/pdd15oo/examples/io/httpd2.pir
==============================================================================
--- branches/pdd15oo/examples/io/httpd2.pir (original)
+++ branches/pdd15oo/examples/io/httpd2.pir Wed Oct 3 10:07:41 2007
@@ -19,8 +19,7 @@
.local pmc d, opts
.local int clid
opts = 'get_config'(args)
- clid = find_type ['HTTP'; 'Daemon']
- d = new clid, opts
+ d = new ['HTTP'; 'Daemon'], opts
unless d goto err
push_eh ignore
$S0 = opts['url']
Modified: branches/pdd15oo/examples/pge/simple.pir
==============================================================================
--- branches/pdd15oo/examples/pge/simple.pir (original)
+++ branches/pdd15oo/examples/pge/simple.pir Wed Oct 3 10:07:41 2007
@@ -6,8 +6,7 @@
.local pmc p6rule
.local string op
- $I0 = find_type "PGE::OPTable"
- optable = new $I0
+ optable = new "PGE::OPTable"
store_global "Simple", "$optable", optable
p6rule = compreg "PGE::P6Rule"