From: fennecdjay Date: Fri, 5 Jul 2019 18:55:14 +0000 (+0200) Subject: :champagne: Allow dynamic operators X-Git-Tag: nightly~2348^2~40 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=c3c2d2ff3056bf3132c5c4e8ba292693fe3cd65e;p=gwion.git :champagne: Allow dynamic operators --- diff --git a/ast b/ast index 288d889c..879a632e 160000 --- a/ast +++ b/ast @@ -1 +1 @@ -Subproject commit 288d889c1479bc51f413836bbebeb63031742215 +Subproject commit 879a632ed9372315428c562077f2b8a811ec74dc diff --git a/examples/Gain.gw b/examples/Gain.gw index 3fada7c2..ccb619d7 100644 --- a/examples/Gain.gw +++ b/examples/Gain.gw @@ -6,7 +6,7 @@ t => g; g.chan(0); spork { while(true) { Math.rand2f(100, 800) => s.freq; .15::second => now; }}; for(int i; i < 5; i++) { - <<>>; + <<< g.op() >>>; i => g.op; 2::second => now; } diff --git a/examples/array_lit.gw b/examples/array_lit.gw index 3db22c1a..e782b2a9 100644 --- a/examples/array_lit.gw +++ b/examples/array_lit.gw @@ -1,6 +1,6 @@ [1,2,3,4]; [ [1,2,3,4], [1,2,3,4] ]; -<<<[1,2,3,4]>>>; +<<< [1,2,3,4] >>>; int i[]; int j[3]; Object o[2]; @@ -12,7 +12,7 @@ Object t[2][12][3][4][5]; int k[1][1]; -<<>>; +<<< i, " ", j, " ", o, " ", p, " ", r, " ", s, " ", t, " ", k >>>; [ 1.0, 2, 3, 4, 5 ]; [ #(0.0, 0.0) ]; diff --git a/examples/array_multiple.gw b/examples/array_multiple.gw index e1a5fff5..fc09c92d 100644 --- a/examples/array_multiple.gw +++ b/examples/array_multiple.gw @@ -4,29 +4,29 @@ class A } A a[4][4]; -<<>>; -<<<2 => a[2][3].i>>>; +<<< a[2][3] >>>; +<<< 2 => a[2][3].i >>>; int i[4][4]; -<<<54 => i[2][3]>>>; +<<< 54 => i[2][3] >>>; float f[4][4]; -<<>>; -<<<12.345 => f[2][3]>>>; +<<< f[2][3] >>>; +<<< 12.345 => f[2][3] >>>; complex c[4][4]; -<<>>; -<<>>; +<<< c[2][3] >>>; +<<< c[2][3].re >>>; polar p[4][4]; -<<>>; -<<>>; +<<< p[2][3] >>>; +<<< p[2][3].mod >>>; Vec3 v[4][4]; -<<>>; -<<>>; +<<< v[2][3] >>>; +<<< v[2][3].x >>>; Vec4 w[4][4]; -<<>>; -<<>>; -<<>>; +<<< w[2][3] >>>; +<<< w[2][3].w >>>; +<<< a[2][3].i >>>; diff --git a/examples/auto.gw b/examples/auto.gw index 6302bd27..13a427c0 100644 --- a/examples/auto.gw +++ b/examples/auto.gw @@ -1,3 +1,3 @@ Object i[4]; for(auto a: i) - <<>>; + <<< a >>>; diff --git a/examples/binary_tmpl.gw b/examples/binary_tmpl.gw index 9b2a9107..1746eb94 100644 --- a/examples/binary_tmpl.gw +++ b/examples/binary_tmpl.gw @@ -1,4 +1,4 @@ -fun void test<~A~>(A a) { <<>>; } +fun void test<~A~>(A a) { <<< a >>>; } 1 => test; 1.3 => test; test(1); diff --git a/examples/channel.gw b/examples/channel.gw index eca3964f..581dae64 100644 --- a/examples/channel.gw +++ b/examples/channel.gw @@ -1,3 +1,3 @@ -<<< dac.chan(-1) >>>; -<<< dac.chan(12) >>>; -<<< dac.chan(0) >>>; +<<< dac.chan(-1) >>>; +<<< dac.chan(12) >>>; +<<< dac.chan(0) >>>; diff --git a/examples/check.gw b/examples/check.gw index 1f871682..78160b90 100644 --- a/examples/check.gw +++ b/examples/check.gw @@ -1 +1 @@ -<< dac; second => now;")>>>; +<<< Machine.check("SinOsc s => dac; second => now;") >>>; diff --git a/examples/class.gw b/examples/class.gw index cd171521..f22d38ae 100644 --- a/examples/class.gw +++ b/examples/class.gw @@ -5,4 +5,4 @@ class C } C c; -<<>>; +<<< c >>>; diff --git a/examples/class_coverage.gw b/examples/class_coverage.gw index 9bba0ea2..a9156aea 100644 --- a/examples/class_coverage.gw +++ b/examples/class_coverage.gw @@ -7,8 +7,8 @@ class C Vec3 v; Vec4 w; Object o; - dtor { <<<"dtor">>>; } + dtor { <<< "dtor" >>>; } } C c; -<<>>; +<<< c >>>; diff --git a/examples/class_enum.gw b/examples/class_enum.gw index de47bbbe..0287045d 100644 --- a/examples/class_enum.gw +++ b/examples/class_enum.gw @@ -5,7 +5,7 @@ class C { two, three }; - <<>>; + <<< zero, " ", one, " ", two, " ", three >>>; } C c; -<<>>; +<<< c >>>; diff --git a/examples/class_func_pointer.gw b/examples/class_func_pointer.gw index 937ba7ea..92f47b64 100644 --- a/examples/class_func_pointer.gw +++ b/examples/class_func_pointer.gw @@ -1,13 +1,13 @@ -fun void test() { <<<"member function.">>>; } +fun void test() { <<< "member function." >>>; } class C { typedef void func_t(); // typedef static void s_func_t(); func_t func_p; // static fun c_t s_func_p; // static s_func_t s_ptr; - fun void test() { <<<"member function.">>>; } - fun void test2() { <<<"member function variant.">>>; } -// fun static void s_test() { <<<"member fun.">>>; } + fun void test() { <<< "member function." >>>; } + fun void test2() { <<< "member function variant." >>>; } +// fun static void s_test() { <<< "member fun." >>>; } // test @=> func_p; // test @=> s_ptr; @@ -19,7 +19,7 @@ class C { //func_p(); test(); -//<<>>;//, func_p>>>; +//<<< test >>>;//, func_p >>>; } diff --git a/examples/class_spork_exp.gw b/examples/class_spork_exp.gw index 1b539b07..5dc34ac4 100644 --- a/examples/class_spork_exp.gw +++ b/examples/class_spork_exp.gw @@ -6,11 +6,11 @@ class C "test"; second => now; string s; - <<< "test spork exp." >>>; + <<< "test spork exp." >>>; } @=> Shred @shred; } C c; -<<>>; +<<< c >>>; me.yield(); second => now; diff --git a/examples/class_spork_func.gw b/examples/class_spork_func.gw index 180fd4f1..5d854c3c 100644 --- a/examples/class_spork_func.gw +++ b/examples/class_spork_func.gw @@ -1,9 +1,9 @@ class C { fun void test() { - <<<"here">>>; + <<< "here" >>>; samp => now; - <<<"and now">>>; + <<< "and now" >>>; } spork this.test(); } diff --git a/examples/complex.gw b/examples/complex.gw index f46dcd02..2d35de88 100644 --- a/examples/complex.gw +++ b/examples/complex.gw @@ -4,7 +4,7 @@ a.re; a.im; a + b; -<<>>; +<<< a - b >>>; a * b; a / b; a => b; @@ -13,8 +13,8 @@ a -=> b; a *=> b; a /=> b; -<<<"end">>>; +<<< "end" >>>; 12 => a.re; 1.4 => a.im; -<<>>; -<<>>; +<<< a.re >>>; +<<< a.im >>>; diff --git a/examples/complex/event2_1.gw b/examples/complex/event2_1.gw index 289fedaa..ae3715d1 100644 --- a/examples/complex/event2_1.gw +++ b/examples/complex/event2_1.gw @@ -3,7 +3,7 @@ class global TestEvent { } second => now; //second => now; -<<<"base ", me>>>; +<<< "base ", me >>>; //TestEvent.e => now; -<<<"ok">>>; +<<< "ok" >>>; second => now; diff --git a/examples/const_fold.gw b/examples/const_fold.gw index d8a05da0..c1d9b3a0 100644 --- a/examples/const_fold.gw +++ b/examples/const_fold.gw @@ -1 +1 @@ -<<<1 + 2 * 3>>>; +<<< 1 + 2 * 3 >>>; diff --git a/examples/const_prop.gw b/examples/const_prop.gw index d02dd99d..8fd4e3d2 100644 --- a/examples/const_prop.gw +++ b/examples/const_prop.gw @@ -1,14 +1,14 @@ int i; -<<<2 => i>>>; -<<>>; -<< i>>>; -<<<13 => i>>>; -<<>>; -<< i>>>; -<<>>; +<<< 2 => i >>>; +<<< i >>>; +<<< i +=> i >>>; +<<< 13 => i >>>; +<<< i >>>; +<<< i +=> i >>>; +<<< i >>>; -<<<1 + 3 + i>>>; -<<>>; -<<<++i>>>; -<<>>; -<<<--i>>>; +<<< 1 + 3 + i >>>; +<<< i++ >>>; +<<< ++i >>>; +<<< i-- >>>; +<<< --i >>>; diff --git a/examples/decl.gw b/examples/decl.gw index 271009cb..9b4ea7b6 100644 --- a/examples/decl.gw +++ b/examples/decl.gw @@ -1,2 +1,2 @@ int i; -<<>>; +<<< i >>>; diff --git a/examples/do_until.gw b/examples/do_until.gw index e3996cd3..235af466 100644 --- a/examples/do_until.gw +++ b/examples/do_until.gw @@ -1,6 +1,6 @@ int i; float f; -do { <<>>; if(maybe) break; } +do { <<< i++ >>>; if(maybe) break; } until(i < 10); -do { <<<1 +=> f>>>; if(maybe)continue; } +do { <<< 1 +=> f >>>; if(maybe)continue; } until(f); diff --git a/examples/doc.gw b/examples/doc.gw index 38c67173..47fea358 100644 --- a/examples/doc.gw +++ b/examples/doc.gw @@ -1,7 +1,7 @@ Machine.add("examples/int.gw"); -Machine.compile("int i;<<<120>>>;"); +Machine.compile("int i;<<< 120 >>>;"); //Machine.compile("int i[error];"); -<< int i; <<>>")>>>; +<<< Machine.check("12 => int i; <<< i >>>") >>>; Machine.check("int i[error];"); Machine.check(null); diff --git a/examples/dtor.gw b/examples/dtor.gw index 61bb92d2..98454a19 100644 --- a/examples/dtor.gw +++ b/examples/dtor.gw @@ -1,10 +1,10 @@ class C { - dtor {<<<1>>>;} + dtor {<<< 1 >>>;} } C c; C d; //me.yield(); -<<<"end of dtor test.">>>; -<<>>; +<<< "end of dtor test." >>>; +<<< c," ", d >>>; diff --git a/examples/dyn_switch.gw b/examples/dyn_switch.gw index 0209d2d2..442a28b5 100644 --- a/examples/dyn_switch.gw +++ b/examples/dyn_switch.gw @@ -1,10 +1,10 @@ 3 => const int i; 2 => const int y; switch(i) { - case 1: <<<1>>>;break; - case 3: <<<3>>>;break; - case y: <<<2>>>;break; + case 1: <<< 1 >>>;break; + case 3: <<< 3 >>>;break; + case y: <<< 2 >>>;break; default: - <<<"0">>>; + <<< "0" >>>; } -<<>>; +<<< y >>>; diff --git a/examples/empty_string.gw b/examples/empty_string.gw index e68db5f5..35e4ed41 100644 --- a/examples/empty_string.gw +++ b/examples/empty_string.gw @@ -1,2 +1,2 @@ "test" => string @s; -<<< s >>>; +<<< s >>>; diff --git a/examples/escape_chars.gw b/examples/escape_chars.gw index d354f2c5..eeaea31d 100644 --- a/examples/escape_chars.gw +++ b/examples/escape_chars.gw @@ -1,4 +1,4 @@ -<<<"\0\'\\\a\b\f\n\r\t\v">>>; +<<< "\0\'\\\a\b\f\n\r\t\v" >>>; '\0'; '\''; '\\'; diff --git a/examples/event.gw b/examples/event.gw index c661fc55..5431860e 100644 --- a/examples/event.gw +++ b/examples/event.gw @@ -1,3 +1,3 @@ Event e; -spork { << now>>>; e.broadcast(); }; -<< now>>>; +spork { <<< second => now >>>; e.broadcast(); }; +<<< e => now >>>; diff --git a/examples/extend_array_type_decl.gw b/examples/extend_array_type_decl.gw index ad3c289a..7ca38ae0 100644 --- a/examples/extend_array_type_decl.gw +++ b/examples/extend_array_type_decl.gw @@ -1,8 +1,8 @@ class C extends int[2] { - <<<"test">>>; + <<< "test" >>>; 123 => int i; } C c; -<<>>; -<<>>; +<<< c.size() >>>; +<<< c.i >>>; diff --git a/examples/float.gw b/examples/float.gw index cef40dc1..a066e832 100644 --- a/examples/float.gw +++ b/examples/float.gw @@ -5,264 +5,264 @@ float a; { float variable1; float variable2; - <<< variable1=variable2 >>>; + <<< variable1=variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1+variable2 >>>; + <<< variable1+variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1-variable2 >>>; + <<< variable1-variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1*variable2 >>>; + <<< variable1*variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1/variable2 >>>; + <<< variable1/variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1&&variable2 >>>; + <<< variable1&&variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1||variable2 >>>; + <<< variable1||variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1==variable2 >>>; + <<< variable1==variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1!=variable2 >>>; + <<< variable1!=variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1>variable2 >>>; + <<< variable1>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1>=variable2 >>>; + <<< variable1>=variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1>>; + <<< variable1>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1<=variable2 >>>; + <<< variable1<=variable2 >>>; } //testing operator for and float { float variable2; - <<< -variable2 >>>; + <<< -variable2 >>>; } //testing operator for and int { int variable2; - <<< !variable2 >>>; + <<< !variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1=>variable2 >>>; + <<< variable1=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1+=>variable2 >>>; + <<< variable1+=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1-=>variable2 >>>; + <<< variable1-=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; - <<< variable1*=>variable2 >>>; + <<< variable1*=>variable2 >>>; } //testing operator for float and float { 1 => float variable1; 1 => float variable2; - <<< variable1/=>variable2 >>>; + <<< variable1/=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1=variable2 >>>; + <<< variable1=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1+variable2 >>>; + <<< variable1+variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1-variable2 >>>; + <<< variable1-variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1*variable2 >>>; + <<< variable1*variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1/variable2 >>>; + <<< variable1/variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1&&variable2 >>>; + <<< variable1&&variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1||variable2 >>>; + <<< variable1||variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1==variable2 >>>; + <<< variable1==variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1!=variable2 >>>; + <<< variable1!=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1>variable2 >>>; + <<< variable1>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1>=variable2 >>>; + <<< variable1>=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1>>; + <<< variable1>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1<=variable2 >>>; + <<< variable1<=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1=>variable2 >>>; + <<< variable1=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1+=>variable2 >>>; + <<< variable1+=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1-=>variable2 >>>; + <<< variable1-=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; - <<< variable1*=>variable2 >>>; + <<< variable1*=>variable2 >>>; } //testing operator for int and float { int variable1; 1 => float variable2; - <<< variable1/=>variable2 >>>; + <<< variable1/=>variable2 >>>; } @@ -270,28 +270,28 @@ float a; { float variable1; int variable2; - <<< variable1=variable2 >>>; + <<< variable1=variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1+variable2 >>>; + <<< variable1+variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1-variable2 >>>; + <<< variable1-variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1*variable2 >>>; + <<< variable1*variable2 >>>; } @@ -299,96 +299,96 @@ float a; { float variable1; int variable2; - <<< variable1/variable2 >>>; + <<< variable1/variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1&&variable2 >>>; + <<< variable1&&variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1||variable2 >>>; + <<< variable1||variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1==variable2 >>>; + <<< variable1==variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1!=variable2 >>>; + <<< variable1!=variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1>variable2 >>>; + <<< variable1>variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1>=variable2 >>>; + <<< variable1>=variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1>>; + <<< variable1>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1<=variable2 >>>; + <<< variable1<=variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1=>variable2 >>>; + <<< variable1=>variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1+=>variable2 >>>; + <<< variable1+=>variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1-=>variable2 >>>; + <<< variable1-=>variable2 >>>; } //testing operator for float and int { float variable1; int variable2; - <<< variable1*=>variable2 >>>; + <<< variable1*=>variable2 >>>; } //testing operator for float and int { 1 => float variable1; 1 => int variable2; - <<< variable1/=>variable2 >>>; + <<< variable1/=>variable2 >>>; } diff --git a/examples/fork.gw b/examples/fork.gw index 0f5ced0b..1e1e76f4 100644 --- a/examples/fork.gw +++ b/examples/fork.gw @@ -1,8 +1,8 @@ fork { - <<<"start">>>; + <<< "start" >>>; 12::samp => now; me.test_cancel(); - <<<"stop">>>; + <<< "stop" >>>; } @=> Fork @f; 1 => f.cancel; diff --git a/examples/func.gw b/examples/func.gw index 74f319f1..493e0ade 100644 --- a/examples/func.gw +++ b/examples/func.gw @@ -1,4 +1,4 @@ fun float testf(){ return 1.1; } fun float testf(float f){ return f; } -<<>>; -<<>>; +<<< testf() >>>; +<<< testf(1.4) >>>; diff --git a/examples/func_pointer.gw b/examples/func_pointer.gw index 6eb9d8f5..3cb5e338 100644 --- a/examples/func_pointer.gw +++ b/examples/func_pointer.gw @@ -1,14 +1,14 @@ typedef void func_t(); func_t func_p; -fun void test1() { <<<"test1">>>; } -fun void test2() { <<<"test2">>>; } +fun void test1() { <<< "test1" >>>; } +fun void test2() { <<< "test2" >>>; } test1 @=> func_p; func_p(); func_p(); func_p(); () => func_p; -<<>>; -<<>>; +<<< func_p >>>; +<<< func_p() >>>; test2 @=> func_p; func_p(); func_p(); diff --git a/examples/func_ptr.gw b/examples/func_ptr.gw index c0cb1da2..80fc7126 100644 --- a/examples/func_ptr.gw +++ b/examples/func_ptr.gw @@ -2,9 +2,9 @@ typedef void Test() // define a few funs -fun void test1(){ <<<"test">>>; }; -fun void test2(){ <<<"another test">>>; }; -fun void test3(){ <<<"yet another test">>>; }; +fun void test1(){ <<< "test" >>>; }; +fun void test2(){ <<< "another test" >>>; }; +fun void test3(){ <<< "yet another test" >>>; }; // create a fun pointer instance Test test; @@ -21,4 +21,4 @@ test(); test3 @=> test; test(); -<<< test3 $ Test>>>; +<<< test3 $ Test >>>; diff --git a/examples/in_class_class.gw b/examples/in_class_class.gw index 724b1296..8b68810b 100644 --- a/examples/in_class_class.gw +++ b/examples/in_class_class.gw @@ -1,5 +1,5 @@ class C { - fun void test<~a~>(a var){ <<>>; } + fun void test<~a~>(a var){ <<< var >>>; } class D { int i;} } @@ -7,4 +7,4 @@ C c; C->D d; C->D @d_ref; -<<< c, " ", d, d_ref >>>; +<<< c, " ", d, d_ref >>>; diff --git a/examples/int.gw b/examples/int.gw index dd470f7e..72c58aec 100644 --- a/examples/int.gw +++ b/examples/int.gw @@ -6,250 +6,250 @@ int a; { int variable1; int variable2; -<<< variable1=variable2 >>>; +<<< variable1=variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1-variable2 >>>; +<<< variable1-variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1*variable2 >>>; +<<< variable1*variable2 >>>; } //testing operator for int and int { int variable1; 1 => int variable2; -<<< variable1/variable2 >>>; +<<< variable1/variable2 >>>; } //testing operator for int and int { int variable1; 1 => int variable2; -<<< variable1%variable2 >>>; +<<< variable1%variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1&&variable2 >>>; +<<< variable1&&variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1||variable2 >>>; +<<< variable1||variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1==variable2 >>>; +<<< variable1==variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1!=variable2 >>>; +<<< variable1!=variable2 >>>; } //testing operator for Object and { Object @variable1; -<<< variable1!= null>>>; +<<< variable1!= null >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1>variable2 >>>; +<<< variable1>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1>=variable2 >>>; +<<< variable1>=variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1>>; +<<< variable1>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1<=variable2 >>>; +<<< variable1<=variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1>>variable2 >>>; +<<< variable1>>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1<>>; +<<< variable1<>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1&variable2 >>>; +<<< variable1&variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1|variable2 >>>; +<<< variable1|variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1^variable2 >>>; +<<< variable1^variable2 >>>; } //testing operator for and int { int variable2; -<<< -variable2 >>>; +<<< -variable2 >>>; } //testing operator for and int { int variable2; -<<< !variable2 >>>; +<<< !variable2 >>>; } //testing operator for int and { int variable1; -<<< variable1++ >>>; +<<< variable1++ >>>; } //testing operator for and int { int variable2; -<<< ++variable2 >>>; +<<< ++variable2 >>>; } //testing operator for int and { int variable1; -<<< variable1-- >>>; +<<< variable1-- >>>; } //testing operator for and int { int variable2; -<<< --variable2 >>>; +<<< --variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1=>variable2 >>>; +<<< variable1=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1+=>variable2 >>>; +<<< variable1+=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1-=>variable2 >>>; +<<< variable1-=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1*=>variable2 >>>; +<<< variable1*=>variable2 >>>; } //testing operator for int and int { 1 => int variable1; 1 => int variable2; -<<< variable1/=>variable2 >>>; +<<< variable1/=>variable2 >>>; } //testing operator for int and int { 1 => int variable1; int variable2; -<<< variable1%=>variable2 >>>; +<<< variable1%=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1<<=>variable2 >>>; +<<< variable1<<=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1>>=>variable2 >>>; +<<< variable1>>=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1&=>variable2 >>>; +<<< variable1&=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1|=>variable2 >>>; +<<< variable1|=>variable2 >>>; } //testing operator for int and int { int variable1; int variable2; -<<< variable1^=>variable2 >>>; +<<< variable1^=>variable2 >>>; } // testing cmp ~1; diff --git a/examples/math.gw b/examples/math.gw index c10cbafb..38f1b4a3 100644 --- a/examples/math.gw +++ b/examples/math.gw @@ -1,93 +1,93 @@ -<<< Math.abs(-1) >>>; -<<< Math.fabs(-1) >>>; -<<< Math.fabs(-1.0) >>>; -<<< Math.rand() >>>; -<<< Math.rand2(0, 0) >>>; -<<< Math.rand2(-1, 1) >>>; -<<< Math.rand2(1, -1) >>>; -<<< Math.randf() >>>; -<<< Math.rand2f(-1, 1) >>>; -<<< Math.rand2f(-1.0, 1) >>>; -<<< Math.rand2f(-1, 1.0) >>>; -<<< Math.rand2f(-1.0, 1.0) >>>; -<<< Math.srand(1.2) >>>; -<<< Math.sgn(1) >>>; -<<< Math.sgn(-1) >>>; -<<< Math.sgn(1.0) >>>; -<<< Math.sgn(-1.0) >>>; +<<< Math.abs(-1) >>>; +<<< Math.fabs(-1) >>>; +<<< Math.fabs(-1.0) >>>; +<<< Math.rand() >>>; +<<< Math.rand2(0, 0) >>>; +<<< Math.rand2(-1, 1) >>>; +<<< Math.rand2(1, -1) >>>; +<<< Math.randf() >>>; +<<< Math.rand2f(-1, 1) >>>; +<<< Math.rand2f(-1.0, 1) >>>; +<<< Math.rand2f(-1, 1.0) >>>; +<<< Math.rand2f(-1.0, 1.0) >>>; +<<< Math.srand(1.2) >>>; +<<< Math.sgn(1) >>>; +<<< Math.sgn(-1) >>>; +<<< Math.sgn(1.0) >>>; +<<< Math.sgn(-1.0) >>>; -<<< Math.hypot(4,5) >>>; +<<< Math.hypot(4,5) >>>; // sin -<<< Math.sin(1) >>>; -<<< Math.sin(1.0) >>>; -<<< Math.sinh(1) >>>; -<<< Math.sinh(1.0) >>>; -<<< Math.asin(1) >>>; -<<< Math.asin(1.0) >>>; -<<< Math.asinh(1) >>>; -<<< Math.asinh(1.0) >>>; +<<< Math.sin(1) >>>; +<<< Math.sin(1.0) >>>; +<<< Math.sinh(1) >>>; +<<< Math.sinh(1.0) >>>; +<<< Math.asin(1) >>>; +<<< Math.asin(1.0) >>>; +<<< Math.asinh(1) >>>; +<<< Math.asinh(1.0) >>>; // cos -<<< Math.cos(1) >>>; -<<< Math.cos(1.0) >>>; -<<< Math.cosh(1) >>>; -<<< Math.cosh(1.0) >>>; -<<< Math.acos(1) >>>; -<<< Math.acos(1.0) >>>; -<<< Math.acosh(1) >>>; -<<< Math.acosh(1.0) >>>; +<<< Math.cos(1) >>>; +<<< Math.cos(1.0) >>>; +<<< Math.cosh(1) >>>; +<<< Math.cosh(1.0) >>>; +<<< Math.acos(1) >>>; +<<< Math.acos(1.0) >>>; +<<< Math.acosh(1) >>>; +<<< Math.acosh(1.0) >>>; // tan -<<< Math.tan(1) >>>; -<<< Math.tan(1.0) >>>; -<<< Math.tanh(1) >>>; -<<< Math.tanh(1.0) >>>; -<<< Math.atan(1) >>>; -<<< Math.atan(1.0) >>>; -<<< Math.atanh(1) >>>; -<<< Math.atanh(1.0) >>>; +<<< Math.tan(1) >>>; +<<< Math.tan(1.0) >>>; +<<< Math.tanh(1) >>>; +<<< Math.tanh(1.0) >>>; +<<< Math.atan(1) >>>; +<<< Math.atan(1.0) >>>; +<<< Math.atanh(1) >>>; +<<< Math.atanh(1.0) >>>; -<<< Math.pow(2, 2) >>>; -<<< Math.pow(2.0, 2) >>>; -<<< Math.pow(2, 2.0) >>>; -<<< Math.pow(2.0, 2.0) >>>; +<<< Math.pow(2, 2) >>>; +<<< Math.pow(2.0, 2) >>>; +<<< Math.pow(2, 2.0) >>>; +<<< Math.pow(2.0, 2.0) >>>; -<<< Math.sqrt(2) >>>; -<<< Math.sqrt(2.0) >>>; -<<< Math.exp(2) >>>; -<<< Math.exp(2.0) >>>; -<<< Math.log(2) >>>; -<<< Math.log(2.0) >>>; -<<< Math.log2(2) >>>; -<<< Math.log2(2.0) >>>; -<<< Math.log10(2) >>>; -<<< Math.log10(2.0) >>>; -<<< Math.floor(2) >>>; -<<< Math.floor(2.0) >>>; -<<< Math.ceil(2) >>>; -<<< Math.ceil(2.0) >>>; -<<< Math.round(2) >>>; -<<< Math.round(2.0) >>>; -<<< Math.trunc(2) >>>; -<<< Math.trunc(2.0) >>>; -<<< Math.fmod(2, 2) >>>; -<<< Math.fmod(2.0, 2) >>>; -<<< Math.fmod(2, 2.0) >>>; -<<< Math.fmod(2.0, 2.0) >>>; -<<< Math.remainder(2, 2) >>>; -<<< Math.remainder(2.0, 2) >>>; -<<< Math.remainder(2, 2.0) >>>; -<<< Math.remainder(2.0, 2.0) >>>; -<<< Math.min(2, 2) >>>; -<<< Math.min(2.0, 2) >>>; -<<< Math.min(2, 2.0) >>>; -<<< Math.min(2.0, 2.0) >>>; -<<< Math.max(2, 2) >>>; -<<< Math.max(2.0, 2) >>>; -<<< Math.max(2, 2.0) >>>; -<<< Math.max(2.0, 2.0) >>>; -<<< Math.atan2(2.0, 2.0) >>>; -<<< Math.isinf(2) >>>; -<<< Math.isinf(2.0) >>>; -<<< Math.isnan(2) >>>; -<<< Math.isnan(2.0) >>>; +<<< Math.sqrt(2) >>>; +<<< Math.sqrt(2.0) >>>; +<<< Math.exp(2) >>>; +<<< Math.exp(2.0) >>>; +<<< Math.log(2) >>>; +<<< Math.log(2.0) >>>; +<<< Math.log2(2) >>>; +<<< Math.log2(2.0) >>>; +<<< Math.log10(2) >>>; +<<< Math.log10(2.0) >>>; +<<< Math.floor(2) >>>; +<<< Math.floor(2.0) >>>; +<<< Math.ceil(2) >>>; +<<< Math.ceil(2.0) >>>; +<<< Math.round(2) >>>; +<<< Math.round(2.0) >>>; +<<< Math.trunc(2) >>>; +<<< Math.trunc(2.0) >>>; +<<< Math.fmod(2, 2) >>>; +<<< Math.fmod(2.0, 2) >>>; +<<< Math.fmod(2, 2.0) >>>; +<<< Math.fmod(2.0, 2.0) >>>; +<<< Math.remainder(2, 2) >>>; +<<< Math.remainder(2.0, 2) >>>; +<<< Math.remainder(2, 2.0) >>>; +<<< Math.remainder(2.0, 2.0) >>>; +<<< Math.min(2, 2) >>>; +<<< Math.min(2.0, 2) >>>; +<<< Math.min(2, 2.0) >>>; +<<< Math.min(2.0, 2.0) >>>; +<<< Math.max(2, 2) >>>; +<<< Math.max(2.0, 2) >>>; +<<< Math.max(2, 2.0) >>>; +<<< Math.max(2.0, 2.0) >>>; +<<< Math.atan2(2.0, 2.0) >>>; +<<< Math.isinf(2) >>>; +<<< Math.isinf(2.0) >>>; +<<< Math.isnan(2) >>>; +<<< Math.isnan(2.0) >>>; diff --git a/examples/member.gw b/examples/member.gw index f4be6565..073d3793 100644 --- a/examples/member.gw +++ b/examples/member.gw @@ -17,16 +17,16 @@ class C C c; // read members -<<< c.i, c.c, c.f, c.v, c.w, c.o >>>; +<<< c.i, c.c, c.f, c.v, c.w, c.o >>>; // call fun members -<<< c.m_i(), " ", c.m_f(), " ", c.m_c(), " ", - c.m_v(), " ", c.m_w(), " ", c.m_o()>>>; +<<< c.m_i(), " ", c.m_f(), " ", c.m_c(), " ", + c.m_v(), " ", c.m_w(), " ", c.m_o() >>>; // write members -<<< 12 => c.i >>>; -<<< 1.2 => c.f >>>; -<<< #(0.1, 2.3) => c.c >>>; -<<< @(0.1, 2.3, 3.4) => c.v >>>; -<<< @(0.1, 2.3, 3.4, 5.4) => c.w >>>; -<<< null @=> c.o >>>; +<<< 12 => c.i >>>; +<<< 1.2 => c.f >>>; +<<< #(0.1, 2.3) => c.c >>>; +<<< @(0.1, 2.3, 3.4) => c.v >>>; +<<< @(0.1, 2.3, 3.4, 5.4) => c.w >>>; +<<< null @=> c.o >>>; diff --git a/examples/member_func.gw b/examples/member_func.gw index b56ed704..c60623a7 100644 --- a/examples/member_func.gw +++ b/examples/member_func.gw @@ -9,6 +9,6 @@ class C } C c; -<<>>; -<<>>; -<<<1.2>>>; +<<< c.testf() >>>; +<<< c.testf(1.4) >>>; +<<< 1.2 >>>; diff --git a/examples/module_coverage.gw b/examples/module_coverage.gw index 3791a8fb..82a17512 100644 --- a/examples/module_coverage.gw +++ b/examples/module_coverage.gw @@ -5,5 +5,5 @@ s => ZeroX z => blackhole; Impulse i => FullRect f => blackhole; Step step => blackhole; second => now; -<<<"end">>>; +<<< "end" >>>; step =< blackhole; diff --git a/examples/object_string.gw b/examples/object_string.gw index 141293c2..e9d639b9 100644 --- a/examples/object_string.gw +++ b/examples/object_string.gw @@ -1,3 +1,3 @@ Object o; string s; -<<< o + s >>>; +<<< o + s >>>; diff --git a/examples/op.gw b/examples/op.gw index 5b3c872e..f439d691 100644 --- a/examples/op.gw +++ b/examples/op.gw @@ -1,7 +1,7 @@ //! test operator operator => void (Object o, int i) { - <<>>; + <<< o, " ", i, " success" >>>; } class C { @@ -11,13 +11,13 @@ class C { //! assign object to C.ref operator => void (Object o, C c) { o @=> c.ref; - <<<"success">>>; + <<< "success" >>>; } //operator int plusplus(null d, int i){} int i; Object o; -<<>>; +<<< o, " ", i >>>; 12 => i; //o => i; C c; diff --git a/examples/op2.gw b/examples/op2.gw index 0f1e51a2..e15552cb 100644 --- a/examples/op2.gw +++ b/examples/op2.gw @@ -3,45 +3,45 @@ class C float f; } -operator => float (C c, C d){ <<<"float => C: ", c.f => d.f>>>; return 2.0;} -operator => int (int i, C d){ <<<"int => C: ", i => d.f>>>; return 2;} -operator => float (float f, C d){ <<<"float => C: ", f => d.f>>>; return 2.0;} -operator => complex (complex c, C d){ <<<"complex => C: ", c.re => d.f>>>; return #(1.2, 6.1);} -operator => polar (polar c, C d){ <<<"complex => C: ", c.mod => d.f>>>; return %(2.3, 4.1);} -operator => Vec3 (Vec3 c, C d){ << d.f>>>; return @(1.2, 6.1, 2.3);} -operator => Vec4 (Vec4 c, C d){ <<<"Vec4 => C: ", c.w => d.f>>>; return @(1.2, 6.1, 2.3, 9.3);} +operator => float (C c, C d){ <<< "float => C: ", c.f => d.f >>>; return 2.0;} +operator => int (int i, C d){ <<< "int => C: ", i => d.f >>>; return 2;} +operator => float (float f, C d){ <<< "float => C: ", f => d.f >>>; return 2.0;} +operator => complex (complex c, C d){ <<< "complex => C: ", c.re => d.f >>>; return #(1.2, 6.1);} +operator => polar (polar c, C d){ <<< "complex => C: ", c.mod => d.f >>>; return %(2.3, 4.1);} +operator => Vec3 (Vec3 c, C d){ <<< c.z => d.f >>>; return @(1.2, 6.1, 2.3);} +operator => Vec4 (Vec4 c, C d){ <<< "Vec4 => C: ", c.w => d.f >>>; return @(1.2, 6.1, 2.3, 9.3);} -operator => float (C d, int c){ <<<"int => C: ", c => d.f>>>; return 2.0;} -operator => float (C d, float f){ <<<"C => float: ", f => d.f>>>; return 2.0;} +operator => float (C d, int c){ <<< "int => C: ", c => d.f >>>; return 2.0;} +operator => float (C d, float f){ <<< "C => float: ", f => d.f >>>; return 2.0;} -operator => float (Vec3 v, float f){ <<<"vec3 => C: ", f, " ", v.x => f>>>; return 2.0;} +operator => float (Vec3 v, float f){ <<< "vec3 => C: ", f, " ", v.x => f >>>; return 2.0;} -operator => complex (C d, complex c){ <<<"complex => C: ", c.re => d.f>>>; return #(1.2, 6.1);} -operator => polar (C d, polar c){ <<<"complex => C: ", c.mod => d.f>>>; return %(2.3, 4.1);} -operator => Vec3 (C d, Vec3 c){ << d.f>>>; return @(1.2, 6.1, 2.3);} -operator => Vec4 (C d, Vec4 c){ <<<"Vec4 => C: ", c.w => d.f>>>; return @(1.2, 6.1, 2.3, 9.3);} +operator => complex (C d, complex c){ <<< "complex => C: ", c.re => d.f >>>; return #(1.2, 6.1);} +operator => polar (C d, polar c){ <<< "complex => C: ", c.mod => d.f >>>; return %(2.3, 4.1);} +operator => Vec3 (C d, Vec3 c){ <<< c.z => d.f >>>; return @(1.2, 6.1, 2.3);} +operator => Vec4 (C d, Vec4 c){ <<< "Vec4 => C: ", c.w => d.f >>>; return @(1.2, 6.1, 2.3, 9.3);} C c, d; 12.3 => c.f; -<<< c => d >>>; -<<< 2 => d >>>; -<<< 2.3 => d >>>; -<<< #(7.2, 1.4) => d >>>; -<<< %(7.2, 1.4) => d >>>; -<<< @(7.2, 1.4, 8.3)>>>; -<<< @(7.2, 1.4, 8.3) => d >>>; -<<< @(7.2, 1.4, 8.3, 2.3) => d >>>; +<<< c => d >>>; +<<< 2 => d >>>; +<<< 2.3 => d >>>; +<<< #(7.2, 1.4) => d >>>; +<<< %(7.2, 1.4) => d >>>; +<<< @(7.2, 1.4, 8.3) >>>; +<<< @(7.2, 1.4, 8.3) => d >>>; +<<< @(7.2, 1.4, 8.3, 2.3) => d >>>; int i; 2 => float f; complex cmp; Vec3 v; -<<>>; +<<< f >>>; v => f; Vec4 w; c => i; -<<>>; -<<>>; +<<< c.f >>>; +<<< f >>>; c => f; c => cmp; c => v; diff --git a/examples/ptr_assign_class.gw b/examples/ptr_assign_class.gw index b49465fa..68d635c8 100644 --- a/examples/ptr_assign_class.gw +++ b/examples/ptr_assign_class.gw @@ -3,8 +3,8 @@ class C typedef void Test(); fun void test1(){}; Test test0; - << test0>>>; + <<< test1 @=> test0 >>>; } C c; -<<>>; +<<< c >>>; diff --git a/examples/repeat.gw b/examples/repeat.gw index 18027b12..8e2da1a4 100644 --- a/examples/repeat.gw +++ b/examples/repeat.gw @@ -1,2 +1,2 @@ repeat(3) - <<<1>>>; + <<< 1 >>>; diff --git a/examples/shred.gw b/examples/shred.gw index 9efb1602..99c6db53 100644 --- a/examples/shred.gw +++ b/examples/shred.gw @@ -1,14 +1,14 @@ -<<< "id ", me.id() >>>; -<<< "running ", me.running() >>>; -<<< "done ", me.done() >>>; -<<< "from_Id ", Shred.fromId(0) >>>; -<<< "from_Id ", Shred.fromId(1) >>>; -<<< "me ", me >>>; -<<< "args ", me.args() >>>; +<<< "id ", me.id() >>>; +<<< "running ", me.running() >>>; +<<< "done ", me.done() >>>; +<<< "from_Id ", Shred.fromId(0) >>>; +<<< "from_Id ", Shred.fromId(1) >>>; +<<< "me ", me >>>; +<<< "args ", me.args() >>>; for (int i; i < me.args(); i++) - <<< "arg ", i, me.arg(i)>>>; -<<>>; -<<>>; + <<< "arg ", i, me.arg(i) >>>; +<<< me.dir(), " ", me.path() >>>; +<<< me.code_dir(), " ", me.code_path() >>>; //me.exit(); // call to non existant arg -<<>>; +<<< me.arg(-1) >>>; diff --git a/examples/shreduler_coverage.gw b/examples/shreduler_coverage.gw index 944408ef..21372ebe 100644 --- a/examples/shreduler_coverage.gw +++ b/examples/shreduler_coverage.gw @@ -1,7 +1,7 @@ -fun void t() { 2::second => now; <<<"child ", me.id()>>>; }; +fun void t() { 2::second => now; <<< "child ", me.id() >>>; }; spork t(); -spork \{ 2::second => now; <<<"child ", me.id()>>>; }(); -spork { 2::second => now; <<<"child ", me.id()>>>; }; -<<<"start">>>; +spork \{ 2::second => now; <<< "child ", me.id() >>>; }(); +spork { 2::second => now; <<< "child ", me.id() >>>; }; +<<< "start" >>>; second => now; -<<>>; +<<< me.id(), " end" >>>; diff --git a/examples/sine2.gw b/examples/sine2.gw index cfe6288c..afb226dc 100644 --- a/examples/sine2.gw +++ b/examples/sine2.gw @@ -1,3 +1,3 @@ SinOsc sinosc => dac; -<<>>; +<<< second >>>; 5::second => now; diff --git a/examples/spork_exp.gw b/examples/spork_exp.gw index 8c3e465c..fd46f212 100644 --- a/examples/spork_exp.gw +++ b/examples/spork_exp.gw @@ -2,17 +2,17 @@ class C { 12 => int i; Object o; -<<>>; +<<< this >>>; spork { "test"; second => now; string s; - <<< this, " test spork exp. " , s>>>; + <<< this, " test spork exp. " , s >>>; } @=> Shred @shred; } C c; -<<>>; +<<< c >>>; me.yield(); second => now; diff --git a/examples/spork_func.gw b/examples/spork_func.gw index ed40d747..27c279b7 100644 --- a/examples/spork_func.gw +++ b/examples/spork_func.gw @@ -1,9 +1,9 @@ class C { fun void test(int i) { - <<<"here => ", i>>>; + <<< "here => ", i >>>; samp => now; - <<<"and now">>>; + <<< "and now" >>>; } } diff --git a/examples/spork_lamba.gw b/examples/spork_lamba.gw index bf63f327..4c421eb1 100644 --- a/examples/spork_lamba.gw +++ b/examples/spork_lamba.gw @@ -1,2 +1,2 @@ -spork \ a { <<>>;}(1); +spork \ a { <<< a >>>;}(1); me.yield(); diff --git a/examples/static.gw b/examples/static.gw index a1fec3bb..66415374 100644 --- a/examples/static.gw +++ b/examples/static.gw @@ -23,15 +23,15 @@ class C } // read members -<<< C.i, C.c, C.f, C.v, C.w, C.o >>>; +<<< C.i, C.c, C.f, C.v, C.w, C.o >>>; // call fun members -<<< C._i(), " ", C._f(), " ", C._c(), " ", C._v(), " ", C._w(), " ", C._o()>>>; +<<< C._i(), " ", C._f(), " ", C._c(), " ", C._v(), " ", C._w(), " ", C._o() >>>; // write members -<<< 12 => C.i >>>; -<<< 1.2 => C.f >>>; -<<< #(0.1, 2.3) => C.c >>>; -<<< @(0.1, 2.3, 3.4) => C.v >>>; -<<< @(0.1, 2.3, 3.4, 5.4) => C.w >>>; -<<< null @=> C.o >>>; +<<< 12 => C.i >>>; +<<< 1.2 => C.f >>>; +<<< #(0.1, 2.3) => C.c >>>; +<<< @(0.1, 2.3, 3.4) => C.v >>>; +<<< @(0.1, 2.3, 3.4, 5.4) => C.w >>>; +<<< null @=> C.o >>>; diff --git a/examples/std.gw b/examples/std.gw index cb324a3b..1ca3c3f2 100644 --- a/examples/std.gw +++ b/examples/std.gw @@ -1,19 +1,19 @@ -<<< Std.clamp(2, 0, 2) >>>; -<<< Std.clampf(2, 0, 2) >>>; -<<< Std.scale(.5, 0, 1, 3, 4) >>>; -<<< Std.system("echo $PWD") >>>; -<<< Std.setenv("TEST_VAR", "test me") >>>; -<<< Std.getenv("TEST_VAR") >>>; -<<< Std.atoi("102") >>>; -<<< Std.atof("0.2") >>>; -<<< Std.itoa(1) >>>; -<<< Std.ctoa('a') >>>; -<<< Std.ftoa(1.2) >>>; -<<< Std.mtof(60) >>>; -<<< Std.ftom(440) >>>; -<<< Std.powtodb(440) >>>; -<<< Std.rmstodb(440) >>>; -<<< Std.dbtopow(440) >>>; -<<< Std.dbtorms(440) >>>; -<<< Std.dbtolin(440) >>>; -<<< Std.lintodb(440) >>>; +<<< Std.clamp(2, 0, 2) >>>; +<<< Std.clampf(2, 0, 2) >>>; +<<< Std.scale(.5, 0, 1, 3, 4) >>>; +<<< Std.system("echo $PWD") >>>; +<<< Std.setenv("TEST_VAR", "test me") >>>; +<<< Std.getenv("TEST_VAR") >>>; +<<< Std.atoi("102") >>>; +<<< Std.atof("0.2") >>>; +<<< Std.itoa(1) >>>; +<<< Std.ctoa('a') >>>; +<<< Std.ftoa(1.2) >>>; +<<< Std.mtof(60) >>>; +<<< Std.ftom(440) >>>; +<<< Std.powtodb(440) >>>; +<<< Std.rmstodb(440) >>>; +<<< Std.dbtopow(440) >>>; +<<< Std.dbtorms(440) >>>; +<<< Std.dbtolin(440) >>>; +<<< Std.lintodb(440) >>>; diff --git a/examples/string.gw b/examples/string.gw index b10b3d01..605cdfa0 100644 --- a/examples/string.gw +++ b/examples/string.gw @@ -15,41 +15,41 @@ s.rfind(1, "su"); s.erase(1, 2); -<<<" su".ltrim()>>>; -<<<" su ".rtrim()>>>; -<<<" su ".trim()>>>; +<<< " su".ltrim() >>>; +<<< " su ".rtrim() >>>; +<<< " su ".trim() >>>; -<<<" su ".charAt(1)>>>; -<<<" su ".charAt(1, 'n')>>>; -<<<" su ".charAt(-1)>>>; -<<<" su ".charAt(-1, 'n')>>>; +<<< " su ".charAt(1) >>>; +<<< " su ".charAt(1, 'n') >>>; +<<< " su ".charAt(-1) >>>; +<<< " su ".charAt(-1, 'n') >>>; s.substring(2); " su ".substring(2); -<<<" su ".substring(2, 1)>>>; -<<<"su".insert(1, "test")>>>; -<<<"su".replace(1, "t")>>>; -<<<"su".replace(1, 2, "turlututu")>>>; -<<<" su ".charAt(1, 'n')>>>; +<<< " su ".substring(2, 1) >>>; +<<< "su".insert(1, "test") >>>; +<<< "su".replace(1, "t") >>>; +<<< "su".replace(1, 2, "turlututu") >>>; +<<< " su ".charAt(1, 'n') >>>; //null @=> s; -<<<1 => s>>>; -<<<1.0 => s>>>; -<<< #(2,1) => s >>>; -<<< %(2,1) => s >>>; -<<< @(2,1,0) => s >>>; -<<< @(2,1,0,-1) => s >>>; -<<<"test" => s>>>; // new -<<<"test" => s>>>; // new -<<>>; -<<< null => s >>>; //test me -<<< o => s >>>; -<<>>; +<<< 1 => s >>>; +<<< 1.0 => s >>>; +<<< #(2,1) => s >>>; +<<< %(2,1) => s >>>; +<<< @(2,1,0) => s >>>; +<<< @(2,1,0,-1) => s >>>; +<<< "test" => s >>>; // new +<<< "test" => s >>>; // new +<<< s >>>; +<<< null => s >>>; //test me +<<< o => s >>>; +<<< o >>>; // look at me!!! -<<< o => s>>>; // hang . grrr ... -<<<"test" + "another test" >>>; // mem leak -<<<"1".toInt()>>>; -<<<"1".toFloat()>>>; +<<< o => s >>>; // hang . grrr ... +<<< "test" + "another test" >>>; // mem leak +<<< "1".toInt() >>>; +<<< "1".toFloat() >>>; //me.exit(); @@ -62,18 +62,18 @@ s.substring(2); //{ ("test" + s) @=> string @str; } // leak -<<< 11 +=> s>>>; -<<< 11.0 +=> s>>>; -<<< #(21,11) +=> s >>>; -<<< %(22,12) +=> s >>>; -<<< @(22,11,11) +=> s >>>; -<<< @(22,11,11,-11) +=> s >>>; -<<< o +=> s>>>; -<<<"test" + s >>>; // also leak -<<< null +=> s >>>; // also hang -<<< "test" +=> s>>>; // test me -<<< "test" == "test" >>>; -<<< "test" != "test" >>>; -<<< "test" == "test1" >>>; -<<< "test" != "test1" >>>; -<<>>; +<<< 11 +=> s >>>; +<<< 11.0 +=> s >>>; +<<< #(21,11) +=> s >>>; +<<< %(22,12) +=> s >>>; +<<< @(22,11,11) +=> s >>>; +<<< @(22,11,11,-11) +=> s >>>; +<<< o +=> s >>>; +<<< "test" + s >>>; // also leak +<<< null +=> s >>>; // also hang +<<< "test" +=> s >>>; // test me +<<< "test" == "test" >>>; +<<< "test" != "test" >>>; +<<< "test" == "test1" >>>; +<<< "test" != "test1" >>>; +<<< string.char('t') >>>; diff --git a/examples/switch.gw b/examples/switch.gw index c34fb47d..4d626a4c 100644 --- a/examples/switch.gw +++ b/examples/switch.gw @@ -3,13 +3,13 @@ int i; fun void test(int i) { switch(i) { case 1: - <<<"'i' is 1">>>; + <<< "'i' is 1" >>>; break; case 2: - <<<"'i' is 2">>>; + <<< "'i' is 2" >>>; break; default: - <<<1, ", ", 2>>>; + <<< 1, ", ", 2 >>>; break; } } diff --git a/examples/tail_call.gw b/examples/tail_call.gw index 029251cd..6e3f1137 100644 --- a/examples/tail_call.gw +++ b/examples/tail_call.gw @@ -1,7 +1,7 @@ fun void test(int i) { if(i == 2)return; // if(i == 0)return; -<<>>; +<<< i >>>; return test(--i + 3 - 4); } diff --git a/examples/template.gw b/examples/template.gw index 32323111..27a3e293 100644 --- a/examples/template.gw +++ b/examples/template.gw @@ -1,4 +1,4 @@ -fun void test<~A~> (A var){ <<< var>>>; } -fun void test<~A,B~> (A var, B var2){ <<< var>>>; } +fun void test<~A~> (A var){ <<< var >>>; } +fun void test<~A,B~> (A var, B var2){ <<< var >>>; } test<~int~>(1); test<~float, float~>(3, 1.4); diff --git a/examples/template_dyn.gw b/examples/template_dyn.gw index aa64a717..60efe516 100644 --- a/examples/template_dyn.gw +++ b/examples/template_dyn.gw @@ -1,24 +1,24 @@ -fun void test(C cc) { <<< cc.test(2) >>>; } +fun void test(C cc) { <<< cc.test(2) >>>; } -fun void test(C cc, int i) { <<<1>>>; <<>>; } +fun void test(C cc, int i) { <<< 1 >>>; <<< cc.test(i, i) >>>; } class C { - fun int test<~A~>(A a) { <<<" A ", a>>>; } - fun int test<~A~>(A a, int i) { <<<" ", a >>>; } - fun int test<~A~>(A a, int i, int j) { <<>>; } + fun int test<~A~>(A a) { <<< " A ", a >>>; } + fun int test<~A~>(A a, int i) { <<< " ", a >>>; } + fun int test<~A~>(A a, int i, int j) { <<< a >>>; } } class D extends C { - fun int test<~A~>(A a, int i) { <<>>; } + fun int test<~A~>(A a, int i) { <<< this, " extent ", a, __func__ >>>; } } class E extends D { - fun int test<~A~>(A a, int i) { <<>>; } + fun int test<~A~>(A a, int i) { <<< this, " Extent ", a, __func__ >>>; } } -<<>>; -<<>>; -<<>>; +<<< C c >>>; +<<< D d >>>; +<<< E e >>>; test(c); test(d); @@ -26,7 +26,7 @@ test(e); test(c,1); test(d,2); test(e,3); -<<>>; +<<< test >>>; c.test(1); @@ -41,7 +41,7 @@ e.test(3); e.test(123,3); e.test(3, 2, 3); -fun void _test() {<<<"test">>>; } +fun void _test() {<<< "test" >>>; } fun void test() { _test(); } test(); diff --git a/examples/template_guess.gw b/examples/template_guess.gw index 40202949..0cc9c740 100644 --- a/examples/template_guess.gw +++ b/examples/template_guess.gw @@ -1,4 +1,4 @@ -fun void test<~A,B~>(A a, B b){<<>>;} +fun void test<~A,B~>(A a, B b){<<< a, ", ", b >>>;} test(1, 2.1); test(1.1, 2.1); test(1.2, 2); diff --git a/examples/template_vararg.gw b/examples/template_vararg.gw index d2d52b6f..83dd8a76 100644 --- a/examples/template_vararg.gw +++ b/examples/template_vararg.gw @@ -1,6 +1,6 @@ fun void test<~A~>(...) { vararg.start; - <<>>; + <<< vararg.i >>>; vararg.end; } test<~int~>(1, 2); diff --git a/examples/typedef_array_extend.gw b/examples/typedef_array_extend.gw index 585085d5..58390296 100644 --- a/examples/typedef_array_extend.gw +++ b/examples/typedef_array_extend.gw @@ -2,4 +2,4 @@ typedef int[2] lol; class C extends lol { } C c; -<<>>; +<<< c.size() >>>; diff --git a/examples/typeof.gw b/examples/typeof.gw index b4c5593f..997321f5 100644 --- a/examples/typeof.gw +++ b/examples/typeof.gw @@ -5,14 +5,14 @@ class C { int i; typeof(i) a; -<<>>; +<<< a >>>; typeof(C.i) b; -<<>>; +<<< b >>>; C c; typeof(c.f) d; -<<>>; +<<< d >>>; -<<>>; +<<< i," ", c >>>; diff --git a/examples/union.gw b/examples/union.gw index 3cbdefb6..a2084721 100644 --- a/examples/union.gw +++ b/examples/union.gw @@ -4,4 +4,4 @@ union Object @ o; }; -<<>>; +<<< i, " ", o >>>; diff --git a/examples/usr_postfix.gw b/examples/usr_postfix.gw index 28d9a777..84b3932e 100644 --- a/examples/usr_postfix.gw +++ b/examples/usr_postfix.gw @@ -3,10 +3,10 @@ i++; class C { int i; } operator ++ int (C c) { - <<<"here">>>; - <<>>; + <<< "here" >>>; + <<< c.i++ >>>; } C c; c++; c++; -<<>>; +<<< c.i >>>; diff --git a/examples/vararg.gw b/examples/vararg.gw index 0751c667..4175fee6 100644 --- a/examples/vararg.gw +++ b/examples/vararg.gw @@ -3,19 +3,19 @@ fun void test(...) { vararg.start; if(i == 0) - <<>>; + <<< vararg.i >>>; else if(i == 1) - <<>>; + <<< vararg.f >>>; else if(i == 2) - <<>>; + <<< vararg.c >>>; else if(i == 3) - <<>>; + <<< vararg.p >>>; else if(i == 4) - <<>>; + <<< vararg.v3 >>>; else if(i == 5) - <<>>; + <<< vararg.v4 >>>; else if(i == 6) - <<>>; + <<< vararg.o >>>; i++; vararg.end; } diff --git a/examples/vec3.gw b/examples/vec3.gw index 6119e4a8..97582e62 100644 --- a/examples/vec3.gw +++ b/examples/vec3.gw @@ -1,25 +1,25 @@ Vec3 v, w; -<<< v.x >>>; -<<< v.y >>>; -<<< v.z >>>; -<<< 1 => v.x >>>; -<<< 2 => v.y >>>; -<<< -12 => v.z >>>; -<<< @(.1, .2, .4) => v >>>; -<<>>; -<<< "set ", v.set(1,2,3) >>>; -<<< "setAll ", v.setAll(1.2) >>>; -<<< "should be 1.2 1.2 1.2 ", v >>>; -<<< "Update ", v.update(2)>>>; -<<< "Update ", v.update(2, .1)>>>; -<<< "Update ", v.supdate(2)>>>; -<<< "Update ", v.supdate(2, .1)>>>; -<<< "magnitude ", v.magnitude() >>>; -<<< "normalize ", v.normalize() >>>; -<<< "interp ", v.interp() >>>; -<<< "interp ", v.interp(2.3) >>>; -<<< "interp ", v.interp(2.3::samp) >>>; +<<< v.x >>>; +<<< v.y >>>; +<<< v.z >>>; +<<< 1 => v.x >>>; +<<< 2 => v.y >>>; +<<< -12 => v.z >>>; +<<< @(.1, .2, .4) => v >>>; +<<< v >>>; +<<< "set ", v.set(1,2,3) >>>; +<<< "setAll ", v.setAll(1.2) >>>; +<<< "should be 1.2 1.2 1.2 ", v >>>; +<<< "Update ", v.update(2) >>>; +<<< "Update ", v.update(2, .1) >>>; +<<< "Update ", v.supdate(2) >>>; +<<< "Update ", v.supdate(2, .1) >>>; +<<< "magnitude ", v.magnitude() >>>; +<<< "normalize ", v.normalize() >>>; +<<< "interp ", v.interp() >>>; +<<< "interp ", v.interp(2.3) >>>; +<<< "interp ", v.interp(2.3::samp) >>>; w.setAll(1); v+w; @@ -34,4 +34,4 @@ w-10.; w/10.; 10.*w; w*10.; -<<<@(23).x>>>; +<<< @(23).x >>>; diff --git a/examples/vec4.gw b/examples/vec4.gw index d2742a11..064361cb 100644 --- a/examples/vec4.gw +++ b/examples/vec4.gw @@ -1,22 +1,22 @@ Vec4 v, w; -<<>>; +<<< v >>>; -<<< v.x >>>; -<<< v.y >>>; -<<< v.z >>>; -<<< v.w >>>; +<<< v.x >>>; +<<< v.y >>>; +<<< v.z >>>; +<<< v.w >>>; -<<< 1 => v.x >>>; -<<< 1 => v.y >>>; -<<< 1 => v.z >>>; -<<< 1 => v.w >>>; -<<< @(.1, .2, .4, .5) => v >>>; +<<< 1 => v.x >>>; +<<< 1 => v.y >>>; +<<< 1 => v.z >>>; +<<< 1 => v.w >>>; +<<< @(.1, .2, .4, .5) => v >>>; -<<< "set ", v.set(1,2,3,4) >>>; -<<< "setAll ", v.setAll(1.2) >>>; -<<< "should be 1.2 1.2 1.2 ", v >>>; -<<< "magnitude ", v.magnitude() >>>; -<<< "normalize ", v.normalize() >>>; +<<< "set ", v.set(1,2,3,4) >>>; +<<< "setAll ", v.setAll(1.2) >>>; +<<< "should be 1.2 1.2 1.2 ", v >>>; +<<< "magnitude ", v.magnitude() >>>; +<<< "normalize ", v.normalize() >>>; w.setAll(1); v+w; v-w; diff --git a/tests/benchmark/binary-trees.gw b/tests/benchmark/binary-trees.gw index 7d8c8e30..ad6013b4 100644 --- a/tests/benchmark/binary-trees.gw +++ b/tests/benchmark/binary-trees.gw @@ -27,8 +27,8 @@ class Tree { 12 => int maxDepth; maxDepth + 1 => int stretchDepth; -<<<"stretch tree of depth ", stretchDepth, " check: ", - Tree.new_Tree(0, stretchDepth).check()>>>; +<<< "stretch tree of depth ", stretchDepth, " check: ", + Tree.new_Tree(0, stretchDepth).check() >>>; Tree.new_Tree(0, maxDepth) @=> Tree@ longLivedTree; @@ -43,9 +43,9 @@ while (depth < stretchDepth) { for (int i; i < iterations; ++i) Tree.new_Tree(i, depth).check() + Tree.new_Tree(-i, depth).check() +=> check; - <<>>; + <<< iterations * 2, " trees of depth ", depth, " check: ", check >>>; 4 /=> iterations; 2 +=> depth; } -<<<"long lived tree of depth ", maxDepth, " check: ", longLivedTree.check()>>>; +<<< "long lived tree of depth ", maxDepth, " check: ", longLivedTree.check() >>>; diff --git a/tests/benchmark/fib-recurs.gw b/tests/benchmark/fib-recurs.gw index fef14c6f..cb667e96 100644 --- a/tests/benchmark/fib-recurs.gw +++ b/tests/benchmark/fib-recurs.gw @@ -4,5 +4,5 @@ fun int recursive_fib(int n) { else return recursive_fib(n - 2) + recursive_fib(n - 1); } -//<<<5 => recursive_fib>>>; -<<<40 => recursive_fib>>>; +//<<< 5 => recursive_fib >>>; +<<< 40 => recursive_fib >>>; diff --git a/tests/benchmark/fib.gw b/tests/benchmark/fib.gw index 9c78eb29..19f56b93 100644 --- a/tests/benchmark/fib.gw +++ b/tests/benchmark/fib.gw @@ -5,4 +5,4 @@ class Fib { } } repeat(5) - <<>>; + <<< Fib.get(28) >>>; diff --git a/tests/benchmark/method-call.gw b/tests/benchmark/method-call.gw index 76073d3c..5a17f900 100644 --- a/tests/benchmark/method-call.gw +++ b/tests/benchmark/method-call.gw @@ -36,7 +36,7 @@ repeat(n) { toggle.activate().value() => val; } -<<>>; +<<< toggle.value() >>>; NthToggle ntoggle; true => val => ntoggle.state; @@ -55,4 +55,4 @@ repeat(n) { ntoggle.activate().value() => val; } -<<>>; +<<< ntoggle.value() >>>; diff --git a/tests/bug/Tester.gw b/tests/bug/Tester.gw index d7a633dc..bba45d65 100644 --- a/tests/bug/Tester.gw +++ b/tests/bug/Tester.gw @@ -8,19 +8,19 @@ Tester t; Object o; Object @ref; "test" => string s; -//<<>>; -//<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +//<<< t.assert_equal("test", 1, 1) >>>; +//<<< t.assert_equal("test", 2, 1) >>>; +<<< t.assert_equal(s, 1, 1) >>>; +<<< t.assert_equal(s, 2, 1 + 1) >>>; +<<< t.assert_equal(s, 2, 1) >>>; +<<< t.assert_equal(s, o, o) >>>; +<<< t.assert_equal(s, o, null) >>>; +<<< t.assert_equal(s, null $ Object, null) >>>; +<<< t.assert_equal(s, ref, null) >>>; +<<< t.assert_not_equal(s, 1, 1) >>>; +<<< t.assert_not_equal(s, 2, 1 + 1) >>>; +<<< t.assert_not_equal(s, 2, 1) >>>; +<<< t.assert_not_equal(s, o, o) >>>; +<<< t.assert_not_equal(s, o, null) >>>; +<<< t.assert_not_equal(s, null $ Object, null) >>>; +<<< t.assert_not_equal(s, ref, null) >>>; diff --git a/tests/bug/array.gw b/tests/bug/array.gw index 87561abc..9d9a1625 100644 --- a/tests/bug/array.gw +++ b/tests/bug/array.gw @@ -28,8 +28,8 @@ class Test_Array v << @(2.1, 3.2, 4.3); w << @(2.1, 3.2, 4.3, 5.4); - <<>>; + <<< i.size() >>>; } Test_Array t; -<<>>; +<<< t >>>; diff --git a/tests/bug/class_doc.gw b/tests/bug/class_doc.gw index c20e5b00..7946c2ff 100644 --- a/tests/bug/class_doc.gw +++ b/tests/bug/class_doc.gw @@ -7,6 +7,6 @@ class C fun void test() {} //! operator operator => void(C c, C d){ - <<>>; + <<< c, " ", d >>>; } } diff --git a/tests/bug/do_until.gw b/tests/bug/do_until.gw index 4a00f464..814004c4 100644 --- a/tests/bug/do_until.gw +++ b/tests/bug/do_until.gw @@ -1,10 +1,10 @@ int i; -do { <<>>; } +do { <<< i++ >>>; } while(i < 6); -do { <<>>; } +do { <<< i-- >>>; } while(i); 6 => float f; -do { <<<1 -=> f>>>; } +do { <<< 1 -=> f >>>; } while(f); diff --git a/tests/bug/do_while.gw b/tests/bug/do_while.gw index b01880d5..a93a5cf1 100644 --- a/tests/bug/do_while.gw +++ b/tests/bug/do_while.gw @@ -1,10 +1,10 @@ 5 => int i; -do { <<>>; } while(i); +do { <<< i-- >>>; } while(i); 5 => float f; -do { <<< 1 -=> f >>>; } while(f > 0.0); -// do { <<< 1 -=> f >>>; } while(f > 0); +do { <<< 1 -=> f >>>; } while(f > 0.0); +// do { <<< 1 -=> f >>>; } while(f > 0); 5 => f; -do { <<< 1 -=> f >>>; } until(f == 0); -//do { <<< 1 -=> f >>>; } until(f == 0.0); +do { <<< 1 -=> f >>>; } until(f == 0); +//do { <<< 1 -=> f >>>; } until(f == 0.0); 5 => i; -do { <<< i-- >>>; } until(!i); +do { <<< i-- >>>; } until(!i); diff --git a/tests/bug/dot_member_func.gw b/tests/bug/dot_member_func.gw index d77c1295..c3df878a 100644 --- a/tests/bug/dot_member_func.gw +++ b/tests/bug/dot_member_func.gw @@ -7,7 +7,7 @@ t => g; g.chan(0); spork { while(true) { Math.rand2f(100, 800) => s.freq; .15::second => now; }}; for(int i; i < 5; i++) { - <<>>; + <<< g.op() >>>; i => g.op; 2::second => now; } diff --git a/tests/bug/float.gw b/tests/bug/float.gw index 9f1dd780..7197eed7 100644 --- a/tests/bug/float.gw +++ b/tests/bug/float.gw @@ -6,484 +6,484 @@ float a; { float variable1; float variable2; -<<< variable1=variable2 >>>; +<<< variable1=variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1-variable2 >>>; +<<< variable1-variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1*variable2 >>>; +<<< variable1*variable2 >>>; } //testing operator for float and float { float variable1; 1 => float variable2; -<<< variable1/variable2 >>>; +<<< variable1/variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1&&variable2 >>>; +<<< variable1&&variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1||variable2 >>>; +<<< variable1||variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1==variable2 >>>; +<<< variable1==variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1!=variable2 >>>; +<<< variable1!=variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1>variable2 >>>; +<<< variable1>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1>=variable2 >>>; +<<< variable1>=variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1>>; +<<< variable1>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1<=variable2 >>>; +<<< variable1<=variable2 >>>; } //testing operator for and float { float variable2; -<<< -variable2 >>>; +<<< -variable2 >>>; } //testing operator for and int { int variable2; -<<< !variable2 >>>; +<<< !variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1=>variable2 >>>; +<<< variable1=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1+=>variable2 >>>; +<<< variable1+=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1-=>variable2 >>>; +<<< variable1-=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1*=>variable2 >>>; +<<< variable1*=>variable2 >>>; } //testing operator for float and float { float variable1; float variable2; -<<< variable1/=>variable2 >>>; +<<< variable1/=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1=variable2 >>>; +<<< variable1=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1-variable2 >>>; +<<< variable1-variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1*variable2 >>>; +<<< variable1*variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1/variable2 >>>; +<<< variable1/variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1&&variable2 >>>; +<<< variable1&&variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1||variable2 >>>; +<<< variable1||variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1==variable2 >>>; +<<< variable1==variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1!=variable2 >>>; +<<< variable1!=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1>variable2 >>>; +<<< variable1>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1>=variable2 >>>; +<<< variable1>=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1>>; +<<< variable1>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1<=variable2 >>>; +<<< variable1<=variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1=>variable2 >>>; +<<< variable1=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1+=>variable2 >>>; +<<< variable1+=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1-=>variable2 >>>; +<<< variable1-=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1*=>variable2 >>>; +<<< variable1*=>variable2 >>>; } //testing operator for int and float { int variable1; float variable2; -<<< variable1/=>variable2 >>>; +<<< variable1/=>variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1-variable2 >>>; +<<< variable1-variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1*variable2 >>>; +<<< variable1*variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1/variable2 >>>; +<<< variable1/variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1&&variable2 >>>; +<<< variable1&&variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1||variable2 >>>; +<<< variable1||variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1==variable2 >>>; +<<< variable1==variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1!=variable2 >>>; +<<< variable1!=variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1>variable2 >>>; +<<< variable1>variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1>=variable2 >>>; +<<< variable1>=variable2 >>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1>>; +<<< variable1>>; } //testing operator for float and int { float variable1; int variable2; -<<< variable1<=variable2 >>>; +<<< variable1<=variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1=>variable2 >>>; +<<< variable1=>variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1-variable2 >>>; +<<< variable1-variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1*variable2 >>>; +<<< variable1*variable2 >>>; } //testing operator for dur and float { dur variable1; float variable2; -<<< variable1*variable2 >>>; +<<< variable1*variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1/variable2 >>>; +<<< variable1/variable2 >>>; } //testing operator for dur and float { dur variable1; float variable2; -<<< variable1/variable2 >>>; +<<< variable1/variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1>variable2 >>>; +<<< variable1>variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1>=variable2 >>>; +<<< variable1>=variable2 >>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1>>; +<<< variable1>>; } //testing operator for dur and dur { dur variable1; dur variable2; -<<< variable1<=variable2 >>>; +<<< variable1<=variable2 >>>; } //testing operator for time and time { time variable1; time variable2; -<<< variable1=>variable2 >>>; +<<< variable1=>variable2 >>>; } //testing operator for dur and time { dur variable1; time variable2; -<<< variable1=>variable2 >>>; +<<< variable1=>variable2 >>>; } //testing operator for dur and { dur variable1; -<<< variable1=> now>>>; +<<< variable1=> now >>>; } //testing operator for time and dur { time variable1; dur variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for dur and time { dur variable1; time variable2; -<<< variable1+variable2 >>>; +<<< variable1+variable2 >>>; } //testing operator for time and time { time variable1; time variable2; -<<< variable1>variable2 >>>; +<<< variable1>variable2 >>>; } //testing operator for time and time { time variable1; time variable2; -<<< variable1>=variable2 >>>; +<<< variable1>=variable2 >>>; } //testing operator for time and time { time variable1; time variable2; -<<< variable1>>; +<<< variable1>>; } //testing operator for time and time { time variable1; time variable2; -<<< variable1<=variable2 >>>; +<<< variable1<=variable2 >>>; } diff --git a/tests/bug/float2.gw b/tests/bug/float2.gw index a88cbecc..33120f40 100644 --- a/tests/bug/float2.gw +++ b/tests/bug/float2.gw @@ -1,82 +1,82 @@ int i; float f,g; -<<< f + 1.0 >>>; -<<< f - 1.0 >>>; -<<< f * 1.0 >>>; -<<< f / 1.0 >>>; +<<< f + 1.0 >>>; +<<< f - 1.0 >>>; +<<< f * 1.0 >>>; +<<< f / 1.0 >>>; -<<< f && 1.0 >>>; -<<< f || 1.0 >>>; +<<< f && 1.0 >>>; +<<< f || 1.0 >>>; -<<< f == 1.0 >>>; -<<< f != 1.0 >>>; +<<< f == 1.0 >>>; +<<< f != 1.0 >>>; -<<< 1 > 1.0 >>>; -<<< 1 >= 1.0 >>>; -<<< 1 < 1.0 >>>; -<<< 1 <= 1.0 >>>; +<<< 1 > 1.0 >>>; +<<< 1 >= 1.0 >>>; +<<< 1 < 1.0 >>>; +<<< 1 <= 1.0 >>>; -<<< -f >>>; -<<< !f >>>; -<<< 1.0 => f>>>; -<<< 1.0 +=> f>>>; -<<< 1.0 -=> f>>>; -<<< 1.0 /=> f>>>; -<<< 1.0 *=> f>>>; +<<< -f >>>; +<<< !f >>>; +<<< 1.0 => f >>>; +<<< 1.0 +=> f >>>; +<<< 1.0 -=> f >>>; +<<< 1.0 /=> f >>>; +<<< 1.0 *=> f >>>; -<<<"if">>>; +<<< "if" >>>; -<<< i + 1.0 >>>; -<<< i - 1.0 >>>; -<<< i * 1.0 >>>; -<<< i / 1.0 >>>; +<<< i + 1.0 >>>; +<<< i - 1.0 >>>; +<<< i * 1.0 >>>; +<<< i / 1.0 >>>; -<<< i && 1.0 >>>; -<<< i || 1.0 >>>; +<<< i && 1.0 >>>; +<<< i || 1.0 >>>; -<<< i == 1.0 >>>; -<<< i != 1.0 >>>; +<<< i == 1.0 >>>; +<<< i != 1.0 >>>; -<<< i > 1.0 >>>; -<<< i >= 1.0 >>>; -<<< i < 1.0 >>>; -<<< i <= 1.0 >>>; +<<< i > 1.0 >>>; +<<< i >= 1.0 >>>; +<<< i < 1.0 >>>; +<<< i <= 1.0 >>>; -<<< -i >>>; -<<< !i >>>; +<<< -i >>>; +<<< !i >>>; -<<<"fi">>>; -<<< 1.0 => i>>>; -<<< 1.0 +=> i>>>; -<<< 1.0 -=> i>>>; -<<< 1.0 /=> i>>>; -<<< 1.0 *=> i>>>; -<<< 1.0 + i >>>; -<<< 1.0 - i >>>; -<<< 1.0 * i >>>; -<<< 1.0 / i >>>; +<<< "fi" >>>; +<<< 1.0 => i >>>; +<<< 1.0 +=> i >>>; +<<< 1.0 -=> i >>>; +<<< 1.0 /=> i >>>; +<<< 1.0 *=> i >>>; +<<< 1.0 + i >>>; +<<< 1.0 - i >>>; +<<< 1.0 * i >>>; +<<< 1.0 / i >>>; -<<< i, 1.0 && i >>>; -<<< i, 1.0 && !i >>>; -<<< 1.0 || i >>>; -<<< 0.0 || i >>>; +<<< i, 1.0 && i >>>; +<<< i, 1.0 && !i >>>; +<<< 1.0 || i >>>; +<<< 0.0 || i >>>; -//<<< 1.0 == i >>>; -//<<< 1.0 != i >>>; +//<<< 1.0 == i >>>; +//<<< 1.0 != i >>>; -<<< 1.0 +=> i >>>; -<<< 1.0 => i >>>; +<<< 1.0 +=> i >>>; +<<< 1.0 => i >>>; -<<< 1.0 -=> i>>>; -<<< 1.0 /=> i>>>; -<<< 1.0 *=> i>>>; +<<< 1.0 -=> i >>>; +<<< 1.0 /=> i >>>; +<<< 1.0 *=> i >>>; -<<< 1.0 > i>>>; -<<< 1.0 >= i>>>; -<<< 1.0 < i>>>; -<<< 1.0 <= i>>>; -<<>>; +<<< 1.0 > i >>>; +<<< 1.0 >= i >>>; +<<< 1.0 < i >>>; +<<< 1.0 <= i >>>; +<<< g >>>; diff --git a/tests/bug/object_string.gw b/tests/bug/object_string.gw index d5a6390f..ff20759c 100644 --- a/tests/bug/object_string.gw +++ b/tests/bug/object_string.gw @@ -1,3 +1,3 @@ Object o; "Object: " => string s; -<<>>; +<<< s + (o + "") >>>; diff --git a/tests/bug/play_with_str.gw b/tests/bug/play_with_str.gw index 2ffc0792..3daf3001 100644 --- a/tests/bug/play_with_str.gw +++ b/tests/bug/play_with_str.gw @@ -1,4 +1,4 @@ "lol" @=> string @s; "test" => s; -<<<"testmem".replace(2, 3, "UKUH")>>>; +<<< "testmem".replace(2, 3, "UKUH") >>>; diff --git a/tests/bug/static_data.gw b/tests/bug/static_data.gw index d5de4737..85729a8d 100644 --- a/tests/bug/static_data.gw +++ b/tests/bug/static_data.gw @@ -7,9 +7,9 @@ class C static Vec4 w; static Object o; } -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< C.i >>>; +<<< C.f >>>; +<<< C.c >>>; +<<< C.v >>>; +<<< C.w >>>; +<<< C.o >>>; diff --git a/tests/error/array_multi_except.gw b/tests/error/array_multi_except.gw index 65a58a18..1e28ca76 100644 --- a/tests/error/array_multi_except.gw +++ b/tests/error/array_multi_except.gw @@ -1,4 +1,4 @@ // [contains] NullPtrException int i[1][1]; null @=> i[0]; -<<>>; +<<< i[0][0] >>>; diff --git a/tests/error/auto_not_array.gw b/tests/error/auto_not_array.gw index 882d11be..d418d9b4 100644 --- a/tests/error/auto_not_array.gw +++ b/tests/error/auto_not_array.gw @@ -1,4 +1,4 @@ // [contains] not allowed in auto loop Object i; for(auto a: i) - <<>>; + <<< a >>>; diff --git a/tests/error/class_enum.gw b/tests/error/class_enum.gw index 1db2538a..d4e68cfa 100644 --- a/tests/error/class_enum.gw +++ b/tests/error/class_enum.gw @@ -5,5 +5,5 @@ class C } C.a; -<<>>; -<<<--C.a>>>; +<<< C.a >>>; +<<< --C.a >>>; diff --git a/tests/error/const_non_mutable.gw b/tests/error/const_non_mutable.gw index c549499f..5b46158e 100644 --- a/tests/error/const_non_mutable.gw +++ b/tests/error/const_non_mutable.gw @@ -1,4 +1,4 @@ // [contains] right-side operand is non-mutable 10 => const int i; 12 => i; -<<>>; +<<< i >>>; diff --git a/tests/error/empty_for.gw b/tests/error/empty_for.gw index e7cd6000..c82dabec 100644 --- a/tests/error/empty_for.gw +++ b/tests/error/empty_for.gw @@ -1,3 +1,3 @@ // [contains] empty for loop condition -<<<"test">>>; +<<< "test" >>>; for(;;){} diff --git a/tests/error/empty_member_ptr.gw b/tests/error/empty_member_ptr.gw index 8a81406d..d950e990 100644 --- a/tests/error/empty_member_ptr.gw +++ b/tests/error/empty_member_ptr.gw @@ -4,6 +4,6 @@ class C typedef void test(); test t; } -<<>>; -<<>>; +<<< C c >>>; +<<< c.t >>>; c.t(); diff --git a/tests/error/func_code_error.gw b/tests/error/func_code_error.gw index cb6a91aa..61041f6c 100644 --- a/tests/error/func_code_error.gw +++ b/tests/error/func_code_error.gw @@ -1,2 +1,2 @@ // [contains] in function: -fun void test() { <<>>; } +fun void test() { <<< b >>>; } diff --git a/tests/error/if_exp_invalid_cond.gw b/tests/error/if_exp_invalid_cond.gw index 79d6a2d6..6e600b40 100644 --- a/tests/error/if_exp_invalid_cond.gw +++ b/tests/error/if_exp_invalid_cond.gw @@ -1,2 +1,2 @@ // [contains] Invalid type -null ? <<<1>>> : <<<2>>>; +null ? <<< 1 >>> : <<< 2 >>>; diff --git a/tests/error/lambda_mismatch1.gw b/tests/error/lambda_mismatch1.gw index 813b1d7e..449f0528 100644 --- a/tests/error/lambda_mismatch1.gw +++ b/tests/error/lambda_mismatch1.gw @@ -1,2 +1,2 @@ // [contains] argument number does not match for lambda -\a b { <<>>; }(1); +\a b { <<< a, " ", b >>>; }(1); diff --git a/tests/error/lambda_mismatch2.gw b/tests/error/lambda_mismatch2.gw index 8ea82eed..808c008b 100644 --- a/tests/error/lambda_mismatch2.gw +++ b/tests/error/lambda_mismatch2.gw @@ -1,4 +1,4 @@ // [contains] argument number does not match for lambda typedef void ptr_t(int i); -\a b { <<>>; } @=> ptr_t ptr; +\a b { <<< a, " ", b >>>; } @=> ptr_t ptr; ptr(2); diff --git a/tests/error/lambda_mismatch3.gw b/tests/error/lambda_mismatch3.gw index 91c91869..d1de1676 100644 --- a/tests/error/lambda_mismatch3.gw +++ b/tests/error/lambda_mismatch3.gw @@ -1,6 +1,6 @@ // [contains] argument number does not match for lambda typedef void ptr_t(int i); -\a b { <<>>; } @=> ptr_t ptr; +\a b { <<< a, " ", b >>>; } @=> ptr_t ptr; fun void test(ptr_t ptr) { ptr(2); } diff --git a/tests/error/loop_not_int.gw b/tests/error/loop_not_int.gw index cb05db54..538e8a3e 100644 --- a/tests/error/loop_not_int.gw +++ b/tests/error/loop_not_int.gw @@ -1,4 +1,4 @@ // [contains] conditional must be of type complex c; repeat(c) - <<<"error">>>; + <<< "error" >>>; diff --git a/tests/error/member_from_static.gw b/tests/error/member_from_static.gw index c8330548..1c69586f 100644 --- a/tests/error/member_from_static.gw +++ b/tests/error/member_from_static.gw @@ -2,6 +2,6 @@ class C { int i; fun static void test() { - <<>>; + <<< i >>>; } } diff --git a/tests/error/negative_array.gw b/tests/error/negative_array.gw index c0852236..b094b399 100644 --- a/tests/error/negative_array.gw +++ b/tests/error/negative_array.gw @@ -1,3 +1,3 @@ // [contains] NegativeArraySize: while allocating arrays int i[-1]; -<<>>; +<<< i >>>; diff --git a/tests/error/negative_array2.gw b/tests/error/negative_array2.gw index 5c825c93..d0646f7d 100644 --- a/tests/error/negative_array2.gw +++ b/tests/error/negative_array2.gw @@ -1,4 +1,4 @@ // [contains] ArrayOutofBounds int i[2][2]; -<<>>; -<<<-1>>>; +<<< i[1][-1] >>>; +<<< -1 >>>; diff --git a/tests/error/no_cast.gw b/tests/error/no_cast.gw index b790243f..7cff67a0 100644 --- a/tests/error/no_cast.gw +++ b/tests/error/no_cast.gw @@ -4,5 +4,5 @@ class D{} C c; D d; -<<>>; -<<>>; +<<< c $ D >>>; +<<< d >>>; diff --git a/tests/error/no_compat_sub2.gw b/tests/error/no_compat_sub2.gw index ac28f797..96d75970 100644 --- a/tests/error/no_compat_sub2.gw +++ b/tests/error/no_compat_sub2.gw @@ -1,4 +1,4 @@ // [contains] incompatible array subscript type Object o; int i[o]; -<<>>; +<<< i >>>; diff --git a/tests/error/null_auto.gw b/tests/error/null_auto.gw index 177793a2..eb45296d 100644 --- a/tests/error/null_auto.gw +++ b/tests/error/null_auto.gw @@ -1,4 +1,4 @@ // [contains] NullPtrException int i[]; for(auto a : i) - <<>>; + <<< a >>>; diff --git a/tests/error/override_confict.gw b/tests/error/override_confict.gw index 0f05c714..72ece0d7 100644 --- a/tests/error/override_confict.gw +++ b/tests/error/override_confict.gw @@ -11,5 +11,5 @@ class D extends C C c; D d; -<<>>; -<<>>; \ No newline at end of file +<<< c >>>; +<<< d >>>; \ No newline at end of file diff --git a/tests/error/private.gw b/tests/error/private.gw index 49cff91e..e71b04db 100644 --- a/tests/error/private.gw +++ b/tests/error/private.gw @@ -2,4 +2,4 @@ class C { private int i; } C c; -<<>>; +<<< c.i >>>; diff --git a/tests/error/private_other.gw b/tests/error/private_other.gw index 2ea5bd98..ee7d52ee 100644 --- a/tests/error/private_other.gw +++ b/tests/error/private_other.gw @@ -3,5 +3,5 @@ class C { private int i; } class D { C c; - <<>>; + <<< c.i >>>; } diff --git a/tests/error/ptr_assign_other.gw b/tests/error/ptr_assign_other.gw index 7f18d51a..ca2caa5c 100644 --- a/tests/error/ptr_assign_other.gw +++ b/tests/error/ptr_assign_other.gw @@ -10,4 +10,4 @@ class D { C c; D d; -<< c.test>>>; +<<< d.test @=> c.test >>>; diff --git a/tests/error/recursive_class_def.gw b/tests/error/recursive_class_def.gw index 6d30f40e..18bfe4fa 100644 --- a/tests/error/recursive_class_def.gw +++ b/tests/error/recursive_class_def.gw @@ -10,7 +10,7 @@ D d; E e; F f; G g; -<<>>; -<<< [ f, g ] >>>; -<<>>; -<<>>; +<<< f $ D >>>; +<<< [ f, g ] >>>; +<<< maybe ? f : D >>>; +<<< c, " ", d, " ", e, " ", g >>>; diff --git a/tests/error/spork_non_func.gw b/tests/error/spork_non_func.gw index a7b63589..6dba49f2 100644 --- a/tests/error/spork_non_func.gw +++ b/tests/error/spork_non_func.gw @@ -1,4 +1,4 @@ // [contains] only function calls can be sporked int i; -<<>>; +<<< i >>>; spork i; diff --git a/tests/error/template_n_mismatch.gw b/tests/error/template_n_mismatch.gw index c912840c..dbd9a538 100644 --- a/tests/error/template_n_mismatch.gw +++ b/tests/error/template_n_mismatch.gw @@ -1,6 +1,6 @@ // [contains] arguments do not match for template call -fun void test<~A~>(){ <<<"func">>>;} -fun void test<~A~>(int i){<<<"other func">>>;} +fun void test<~A~>(){ <<< "func" >>>;} +fun void test<~A~>(int i){<<< "other func" >>>;} test<~int, float, int~>(); //test<~int~>(); diff --git a/tests/error/template_unknown.gw b/tests/error/template_unknown.gw index 85e15132..f9d96219 100644 --- a/tests/error/template_unknown.gw +++ b/tests/error/template_unknown.gw @@ -1,4 +1,4 @@ // [contains] unknown type -fun void my_function<~A~>() { <<<"test">>>; } +fun void my_function<~A~>() { <<< "test" >>>; } my_function<~unknown_type~>(); diff --git a/tests/error/this_static.gw b/tests/error/this_static.gw index a44f0bfe..8483049b 100644 --- a/tests/error/this_static.gw +++ b/tests/error/this_static.gw @@ -1,5 +1,5 @@ // [contains] keyword 'this' cannot be used inside static functions class C { - fun static void test(){ <<>>; } + fun static void test(){ <<< this >>>; } } diff --git a/tests/error/undef_parent.gw b/tests/error/undef_parent.gw index 34a62f8a..47a83ed3 100644 --- a/tests/error/undef_parent.gw +++ b/tests/error/undef_parent.gw @@ -1,4 +1,4 @@ // [contains] unknown type class C extends Undefined {} C c; -<<>>; \ No newline at end of file +<<< c >>>; \ No newline at end of file diff --git a/tests/error/union_object_ref.gw b/tests/error/union_object_ref.gw index c0437706..5e626dbf 100644 --- a/tests/error/union_object_ref.gw +++ b/tests/error/union_object_ref.gw @@ -5,4 +5,4 @@ union Object o; }; -<<>>; +<<< i, " ", o >>>; diff --git a/tests/fptr/class_ptr01.gw b/tests/fptr/class_ptr01.gw index d1d2f54e..04df1a4e 100644 --- a/tests/fptr/class_ptr01.gw +++ b/tests/fptr/class_ptr01.gw @@ -1,6 +1,6 @@ //[contains] cant't assign class C { - fun static void test(int i) { <<< "int arg" >>>; } + fun static void test(int i) { <<< "int arg" >>>; } typedef void PtrType(int i); test @=> PtrType p; p(1); diff --git a/tests/fptr/class_ptr1.gw b/tests/fptr/class_ptr1.gw index 32ffaaa0..f964e588 100644 --- a/tests/fptr/class_ptr1.gw +++ b/tests/fptr/class_ptr1.gw @@ -1,5 +1,5 @@ class C { - fun void test(int i) { <<< "int arg" >>>; } + fun void test(int i) { <<< "int arg" >>>; } typedef static void PtrType(int i); test @=> PtrType p; diff --git a/tests/fptr/class_ptr2.gw b/tests/fptr/class_ptr2.gw index d57a8e83..dd64e231 100644 --- a/tests/fptr/class_ptr2.gw +++ b/tests/fptr/class_ptr2.gw @@ -1,5 +1,5 @@ class C { - fun void test(int i) { <<< "int arg" >>>; } + fun void test(int i) { <<< "int arg" >>>; } typedef void PtrType(int i); test @=> static PtrType p; diff --git a/tests/fptr/class_ptr3.gw b/tests/fptr/class_ptr3.gw index f8976b71..524df8d6 100644 --- a/tests/fptr/class_ptr3.gw +++ b/tests/fptr/class_ptr3.gw @@ -1,5 +1,5 @@ class C { - fun static void test(int i) { <<< "int arg" >>>; } + fun static void test(int i) { <<< "int arg" >>>; } typedef static void PtrType(int i); test @=> static PtrType p; @@ -8,4 +8,4 @@ class C { p(1); } C c; -<<>>; +<<< c >>>; diff --git a/tests/fptr/class_ptr31.gw b/tests/fptr/class_ptr31.gw index ce2cebc5..46ebf444 100644 --- a/tests/fptr/class_ptr31.gw +++ b/tests/fptr/class_ptr31.gw @@ -1,6 +1,6 @@ // [contains] can't assign class C { - fun void test(int i) { <<< "int arg" >>>; } + fun void test(int i) { <<< "int arg" >>>; } typedef static void PtrType(int i); test @=> static PtrType p; diff --git a/tests/import/callback2.gw b/tests/import/callback2.gw index c9f0668d..91f4f5cb 100644 --- a/tests/import/callback2.gw +++ b/tests/import/callback2.gw @@ -1,15 +1,15 @@ -fun Vec4 test(int i) { <<<"test with arg ", i>>>; } +fun Vec4 test(int i) { <<< "test with arg ", i >>>; } //typedef Vec4 PT(); //test @=> PtrTypeI p; test @=> p; //test @=> PT ti; -<<>>; -//<<>>; -<<

>>; -<<>>; -<<>>; +<<< p >>>; +<<< p.key >>>; +<<< p.val >>>; diff --git a/tests/import/global_func.gw b/tests/import/global_func.gw index 4fa22811..c4a56122 100644 --- a/tests/import/global_func.gw +++ b/tests/import/global_func.gw @@ -1,3 +1,3 @@ -<<>>; -<<<1 => test>>>; +<<< test >>>; +<<< 1 => test >>>; diff --git a/tests/import/global_var.gw b/tests/import/global_var.gw index a4041bca..276696d1 100644 --- a/tests/import/global_var.gw +++ b/tests/import/global_var.gw @@ -1 +1 @@ -<<>>; +<<< i >>>; diff --git a/tests/import/map2.gw b/tests/import/map2.gw index 4834e845..6ffb0576 100644 --- a/tests/import/map2.gw +++ b/tests/import/map2.gw @@ -1,5 +1,5 @@ <~int, float~>Map pp; -<<>>; -<<>>; -<<>>; -<<>>; +<<< pp >>>; +<<< pp.size() >>>; +<<< pp.set(1, 2) >>>; +<<< pp.get(1) >>>; diff --git a/tests/import/op_err.c b/tests/import/op_err.c deleted file mode 100644 index 1005ab86..00000000 --- a/tests/import/op_err.c +++ /dev/null @@ -1,19 +0,0 @@ -#include "gwion_util.h" -#include "gwion_ast.h" -#include "oo.h" -#include "vm.h" -#include "env.h" -#include "type.h" -#include "object.h" -#include "instr.h" -#include "gwion.h" -#include "operator.h" -#include "import.h" - -GWION_IMPORT(op_err_test) { - gwi_oper_ini(gwi, "int", "int", "int"); // ignore the check - gwi_oper_end(gwi, 220, NULL); // ignore the check. - CHECK_BB(gwi_oper_ini(gwi, "int", "int", "int")) - CHECK_BB(gwi_oper_end(gwi, op_chuck, NULL)) - return GW_OK; -} diff --git a/tests/import/static_string.gw b/tests/import/static_string.gw index fadda99b..60da0664 100644 --- a/tests/import/static_string.gw +++ b/tests/import/static_string.gw @@ -1,2 +1,2 @@ -//<<>>; -<<>>; +//<<< StaticString.self >>>; +<<< self >>>; diff --git a/tests/import/typedef.gw b/tests/import/typedef.gw index 25282b0d..28639334 100644 --- a/tests/import/typedef.gw +++ b/tests/import/typedef.gw @@ -1,4 +1,4 @@ -fun void test(){ <<<"test">>>; } +fun void test(){ <<< "test" >>>; } PtrType ptr; test(); test @=> ptr; @@ -6,8 +6,8 @@ ptr(); FuncTypedef.test_func(); -<< FuncTypedef.ptr>>>; +<<< FuncTypedef.test_func @=> FuncTypedef.ptr >>>; _ptr; -<<>>; +<<< FuncTypedef.ptr >>>; FuncTypedef.ptr(); diff --git a/tests/import/union.gw b/tests/import/union.gw index b838c6a6..1d9f3a1b 100644 --- a/tests/import/union.gw +++ b/tests/import/union.gw @@ -1,8 +1,8 @@ Union u; -<<>>; -<<<12 => u.f>>>; -<<<1 => u.i>>>; -<<>>; -<<>>; -<<<0 => u.i>>>; -<< u.o>>>; +<<< u.i >>>; +<<< 12 => u.f >>>; +<<< 1 => u.i >>>; +<<< u.i >>>; +<<< u.f >>>; +<<< 0 => u.i >>>; +<<< null @=> u.o >>>; diff --git a/tests/import/variadic.gw b/tests/import/variadic.gw index fe54f6f1..00477db7 100644 --- a/tests/import/variadic.gw +++ b/tests/import/variadic.gw @@ -1,7 +1,7 @@ -<<<"test builtin variadic fun">>>; +<<< "test builtin variadic fun" >>>; Variadic v; "iiii" => string format; -<<>>; +<<< v, " ", format $ Object >>>; v.member(format, 1,2,3,4); v.member(format, 1,2,3,4); v.test(); diff --git a/tests/new/break.gw b/tests/new/break.gw index fb4a5da4..d3f5f2be 100644 --- a/tests/new/break.gw +++ b/tests/new/break.gw @@ -1,8 +1,8 @@ fun void t(int i) { - <<>>; + <<< i >>>; if(!i) 1/i; - <<<"id: ", (spork t(i-1)).id()>>>; + <<< "id: ", (spork t(i-1)).id() >>>; me.yield(); //samp => now; } @@ -10,4 +10,4 @@ fun void t(int i) { //me.yield(); second => now; me.yield(); -<<<"end">>>; +<<< "end" >>>; diff --git a/tests/new/float.gw b/tests/new/float.gw index 7143539e..a872e0d5 100644 --- a/tests/new/float.gw +++ b/tests/new/float.gw @@ -2,4 +2,4 @@ class C { 1 => float f; } C c; -<<>>; +<<< c.f >>>; diff --git a/tests/new/global_func0.gw b/tests/new/global_func0.gw index cc852b45..2773c4fd 100644 --- a/tests/new/global_func0.gw +++ b/tests/new/global_func0.gw @@ -2,10 +2,10 @@ class global C { 13 => int i; } -<<>>; +<<< g_i >>>; global C g_c; -<<i => ", g_c.i>>>; -fun global void g_test() { <<>>; <<>>; <<>>; <<<"test">>>; } -//fun global void g_test() { <<<"test">>>; } -<<>>; -<<>>; +<<< g_c, "->i => ", g_c.i >>>; +fun global void g_test() { <<< g_i >>>; <<< g_c >>>; <<< g_c.i >>>; <<< "test" >>>; } +//fun global void g_test() { <<< "test" >>>; } +<<< g_test >>>; +<<< g_test() >>>; diff --git a/tests/new/global_func1.gw b/tests/new/global_func1.gw index 42224657..e6935d9c 100644 --- a/tests/new/global_func1.gw +++ b/tests/new/global_func1.gw @@ -1,7 +1,7 @@ -<<>>; -<<>>; -<<>>; -<<>>; +<<< g_i >>>; +<<< g_c >>>; +<<< g_c.i >>>; +<<< g_test >>>; g_test(); //g_test(); diff --git a/tests/new/global_func3.gw b/tests/new/global_func3.gw index fea54e50..061dfa3e 100644 --- a/tests/new/global_func3.gw +++ b/tests/new/global_func3.gw @@ -1,4 +1,4 @@ -<<>>; +<<< int i >>>; fun global void this_global_func_will_fail_to_compile() { - <<>>; + <<< i >>>; } diff --git a/tests/new/global_var.gw b/tests/new/global_var.gw index 97ac7a60..072245a2 100644 --- a/tests/new/global_var.gw +++ b/tests/new/global_var.gw @@ -1 +1 @@ -<<>>; +<<< global int g_i >>>; diff --git a/tests/new/global_var1.gw b/tests/new/global_var1.gw index 1e65cc55..38c15585 100644 --- a/tests/new/global_var1.gw +++ b/tests/new/global_var1.gw @@ -1 +1 @@ -<<>>; +<<< g_i >>>; diff --git a/tests/new/lambda.gw b/tests/new/lambda.gw index 86b744e5..83b2a3b3 100644 --- a/tests/new/lambda.gw +++ b/tests/new/lambda.gw @@ -1,32 +1,32 @@ class C { typedef void ptr_t(int i,int j); - \a b { <<>>; } @=> ptr_t ptr; -// `a,b` { <<<"test">>>; } @=> + \a b { <<< this, " ", a, " ", b, " test" >>>; } @=> ptr_t ptr; +// `a,b` { <<< "test" >>>; } @=> // ptr_t ptr; // ptr(1,2); - fun void test(int i, int j) { <<>>; } + fun void test(int i, int j) { <<< this, " ", i, " ", j >>>; } // fun void test(ptr_t t, int i) { -//<<>>; +//<<< t >>>; // t(2,i); // } -// test(`a,b` { <<>>; }, 2); +// test(`a,b` { <<< this, " lambda argument" >>>; }, 2); } -//<<>>; +//<<< C c >>>; C c; -<<>>; -//<<>>; -//<<>>; +<<< c >>>; +//<<< c.test >>>; +//<<< c.ptr >>>; //c.ptr(1,2); -//<<>>; +//<<< c.test >>>; c.test @=> c.ptr; //c.ptr; -//<<>>; +//<<< c.ptr >>>; //c.test(1,2); c.ptr(1, 2); //c.ptr(1, 2); //c.ptr(1, 2); //(1,2) => c.ptr; -//c.test(`a,b` { <<>>; }, 2); +//c.test(`a,b` { <<< this, "lambda argument" >>>; }, 2); //c.test(c.ptr, 2); -//<<>>; +//<<< c.ptr >>>; //c.ptr; diff --git a/tests/new/lambda2.gw b/tests/new/lambda2.gw index f45c8fc6..e8a0474c 100644 --- a/tests/new/lambda2.gw +++ b/tests/new/lambda2.gw @@ -1,21 +1,21 @@ class C { typedef void ptr_t(int i); -\a { <<>>; } @=> +\a { <<< this, " ", a >>>; } @=> ptr_t ptr; //ptr(3); -fun void t1(int i) { <<>>; } +fun void t1(int i) { <<< this, " t1 ", i >>>; } fun void test(ptr_t ptr) { -<<>>; +<<< this >>>; ptr(1); } t1 @=> ptr_t t1p; //test(t1$ptr_t); test(t1p); //test(ptr); -//<<>>; -//<<>>; +//<<< t1 >>>; +//<<< t1$ptr_t >>>; } -<<>>; -<<>>; -<<>>; +<<< C c >>>; +<<< c.test(c.ptr) >>>; +<<< c.ptr(1) >>>; c.test(c.t1p); diff --git a/tests/new/lambda3.gw b/tests/new/lambda3.gw index 990d0f9b..fb39c19e 100644 --- a/tests/new/lambda3.gw +++ b/tests/new/lambda3.gw @@ -1,2 +1,2 @@ 12 => int i; -\a b { <<<"i: ", i, " ", a, " ", b>>>; }(1,2); +\a b { <<< "i: ", i, " ", a, " ", b >>>; }(1,2); diff --git a/tests/new/local_func.gw b/tests/new/local_func.gw index 1d0e7ccb..895be414 100644 --- a/tests/new/local_func.gw +++ b/tests/new/local_func.gw @@ -1,4 +1,4 @@ fun void test() { - <<>>; + <<< test >>>; } test(); diff --git a/tests/new/spork.gw b/tests/new/spork.gw index 81e571fc..6003f577 100644 --- a/tests/new/spork.gw +++ b/tests/new/spork.gw @@ -1,11 +1,11 @@ -fun void _t() { <<<__func__>>>; } +fun void _t() { <<< __func__ >>>; } fun int t() { -//<<<1>>>; +//<<< 1 >>>; spork _t(); - spork \a{ <<<__func__, " ", a>>>; }(1); + spork \a{ <<< __func__, " ", a >>>; }(1); - spork { <<<__func__>>>; }; + spork { <<< __func__ >>>; }; } spork t(); t(); diff --git a/tests/new/spork2.gw b/tests/new/spork2.gw index ef8814b9..8acf418f 100644 --- a/tests/new/spork2.gw +++ b/tests/new/spork2.gw @@ -1,21 +1,21 @@ -fun void _t() { <<<__func__>>>; } +fun void _t() { <<< __func__ >>>; } class C { -<<>>; -fun void __t() { <<<__func__>>>; } -fun void __t(int i) { <<>>; } +<<< this >>>; +fun void __t() { <<< __func__ >>>; } +fun void __t(int i) { <<< this, " ", __func__, " ", i >>>; } fun void t() { spork _t(); spork _t(); spork this.__t(); spork __t(); -<<>>; +<<< this >>>; spork __t(2); me.yield(); - spork \{ <<<" " , __func__>>>; }(); + spork \{ <<< " " , __func__ >>>; }(); - spork \a{ <<<__func__, " ", a>>>; }(1); + spork \a{ <<< __func__, " ", a >>>; }(1); - spork { <<<__func__>>>; }; + spork { <<< __func__ >>>; }; } spork t(); spork t(); @@ -23,5 +23,5 @@ t(); t(); me.yield(); } -<<>>; +<<< C c >>>; me.yield(); diff --git a/tests/new/spork_in_func.gw b/tests/new/spork_in_func.gw index e5bfe256..2aebdf88 100644 --- a/tests/new/spork_in_func.gw +++ b/tests/new/spork_in_func.gw @@ -1,8 +1,8 @@ fun void test() { -// <<<1>>>; -//spork \{<<<2>>>;}(); +// <<< 1 >>>; +//spork \{<<< 2 >>>;}(); } test(); test(); -<<<"end">>>; +<<< "end" >>>; me.yield(); diff --git a/tests/new/stackov.gw b/tests/new/stackov.gw index 283adec2..7c197ad2 100644 --- a/tests/new/stackov.gw +++ b/tests/new/stackov.gw @@ -1,12 +1,12 @@ fun void test(int i) { - <<<"test ", i>>>; + <<< "test ", i >>>; if(i > 1) test(i-1); } fun void launch(int i) { test(12); - <<<" launch ", i>>>; + <<< " launch ", i >>>; } spork launch(2); diff --git a/tests/new/stackov2.gw b/tests/new/stackov2.gw index 08c1c9e7..8b948eea 100644 --- a/tests/new/stackov2.gw +++ b/tests/new/stackov2.gw @@ -1,5 +1,5 @@ fun void launch(int i) { -<<<" launch ", i>>>; +<<< " launch ", i >>>; } //spork launch(2); me.yield(); diff --git a/tests/new/static.gw b/tests/new/static.gw index d16d65bc..5ccef63d 100644 --- a/tests/new/static.gw +++ b/tests/new/static.gw @@ -1,4 +1,4 @@ -class C { fun static C t() { C c; <<>>; +class C { fun static C t() { C c; <<< c, " something" >>>; return c; } } //C c; -<<>>; +<<< C.t() >>>; diff --git a/tests/pp/call_not_enough.gw b/tests/pp/call_not_enough.gw index 6fc79d17..94e5b7dd 100644 --- a/tests/pp/call_not_enough.gw +++ b/tests/pp/call_not_enough.gw @@ -1,3 +1,3 @@ //[contains] not enough arguments #define macro(a, b) a, b -<<>>; +<<< macro(1) >>>; diff --git a/tests/pp/call_too_many.gw b/tests/pp/call_too_many.gw index 82403d76..e29f4726 100644 --- a/tests/pp/call_too_many.gw +++ b/tests/pp/call_too_many.gw @@ -1,3 +1,3 @@ //[contains] too many arguments #define macro(a) a -<<>>; +<<< macro(1,2) >>>; diff --git a/tests/pp/conditional.gw b/tests/pp/conditional.gw index 995339ce..30be49b6 100644 --- a/tests/pp/conditional.gw +++ b/tests/pp/conditional.gw @@ -2,13 +2,13 @@ //[contains] 'macro' undefined (after undefining)" #define macro #ifdef macro -<<<"'macro' defined">>>; +<<< "'macro' defined" >>>; #else -<<<"'macro' undefined">>>; +<<< "'macro' undefined" >>>; #endif #undef macro #ifdef macro -<<<"'macro' defined (after undefining)">>>; +<<< "'macro' defined (after undefining)" >>>; #else -<<<"'macro' undefined (after undefining)">>>; +<<< "'macro' undefined (after undefining)" >>>; #endif diff --git a/tests/pp/define_empty.gw b/tests/pp/define_empty.gw index 8355bb1f..754c7b08 100644 --- a/tests/pp/define_empty.gw +++ b/tests/pp/define_empty.gw @@ -2,4 +2,4 @@ #define macro macro -<<<"end of test">>>; +<<< "end of test" >>>; diff --git a/tests/pp/define_empty_args.gw b/tests/pp/define_empty_args.gw index d5524a52..2eeeec08 100644 --- a/tests/pp/define_empty_args.gw +++ b/tests/pp/define_empty_args.gw @@ -2,4 +2,4 @@ #define macro(a,b) macro(1,2); -<<<"end of test">>>; +<<< "end of test" >>>; diff --git a/tests/pp/define_empty_vararg.gw b/tests/pp/define_empty_vararg.gw index a91e098b..a096c61b 100644 --- a/tests/pp/define_empty_vararg.gw +++ b/tests/pp/define_empty_vararg.gw @@ -1,3 +1,3 @@ //[contains] 123 #define macro(...) __VA_ARGS__ -<<>>; +<<< macro(1,2,3) >>>; diff --git a/tests/pp/define_text.gw b/tests/pp/define_text.gw index ed165ee7..d91f89e2 100644 --- a/tests/pp/define_text.gw +++ b/tests/pp/define_text.gw @@ -1,3 +1,3 @@ //[contains] test #define macro "test" -<<>>; +<<< macro >>>; diff --git a/tests/pp/define_text_args.gw b/tests/pp/define_text_args.gw index a515be3a..82171662 100644 --- a/tests/pp/define_text_args.gw +++ b/tests/pp/define_text_args.gw @@ -1,3 +1,3 @@ //[contains] test12 #define macro(a,b) "test", a, b -<<>>; +<<< macro(1,2) >>>; diff --git a/tests/pp/header.gw b/tests/pp/header.gw index a70b4df1..e6e64bc8 100644 --- a/tests/pp/header.gw +++ b/tests/pp/header.gw @@ -1 +1 @@ -<<<__file__>>>; +<<< __file__ >>>; diff --git a/tests/sh/plugin.sh b/tests/sh/plugin.sh index 1cc461fb..8d46d6e3 100644 --- a/tests/sh/plugin.sh +++ b/tests/sh/plugin.sh @@ -1,5 +1,5 @@ #!/bin/bash -# [test] #29 +# [test] #28 n=0 [ "$1" ] && n="$1" diff --git a/tests/tree/array_empty.gw b/tests/tree/array_empty.gw index 1985cb20..7e86696b 100644 --- a/tests/tree/array_empty.gw +++ b/tests/tree/array_empty.gw @@ -1,2 +1,2 @@ int i[][][]; -<<>>; +<<< i >>>; diff --git a/tests/tree/array_test.gw b/tests/tree/array_test.gw index 82abecbc..8da945dd 100644 --- a/tests/tree/array_test.gw +++ b/tests/tree/array_test.gw @@ -1,18 +1,18 @@ fun void print_array(int a[]){ for(int i; i < a.size(); i++) - <<>>; + <<< a[i] >>>; } int i[3][3]; 1 => i[2][0]; -<<>>; -<<>>; -<<>>; +<<< i.size() >>>; +<<< i.depth() >>>; +<<< i.cap() >>>; print_array(i[2]); i.remove(1); -<<>>; -<<>>; -<<>>; -<<>>; +<<< i[1][0] >>>; +<<< i.size() >>>; +<<< i.depth() >>>; +<<< i.cap() >>>; print_array(i[1]); diff --git a/tests/tree/ast_doc.gw b/tests/tree/ast_doc.gw index 4ca5e197..8601f0f5 100644 --- a/tests/tree/ast_doc.gw +++ b/tests/tree/ast_doc.gw @@ -1,3 +1,3 @@ int i; -<<>>; +<<< i >>>; //! document the AST diff --git a/tests/tree/auto_decl.gw b/tests/tree/auto_decl.gw index e90c9623..f840c7b3 100644 --- a/tests/tree/auto_decl.gw +++ b/tests/tree/auto_decl.gw @@ -1,2 +1,2 @@ -<< auto i>>>; -<<>>; \ No newline at end of file +<<< new float[3] @=> auto i >>>; +<<< i >>>; \ No newline at end of file diff --git a/tests/tree/auto_ptr.gw b/tests/tree/auto_ptr.gw index d33242f2..54adfa59 100644 --- a/tests/tree/auto_ptr.gw +++ b/tests/tree/auto_ptr.gw @@ -1,5 +1,5 @@ <~int~>Ptr ptr; int i[4]; for(auto@ a : i) - <<<*a>>>; -<<>>; + <<< *a >>>; +<<< ptr >>>; diff --git a/tests/tree/branch_eq_float.gw b/tests/tree/branch_eq_float.gw index 2dbc1e8f..6019502d 100644 --- a/tests/tree/branch_eq_float.gw +++ b/tests/tree/branch_eq_float.gw @@ -1,10 +1,10 @@ float f; if(f) - <<<"not ok">>>; + <<< "not ok" >>>; else - <<<"ok">>>; + <<< "ok" >>>; while(f) - <<<"not ok">>>; + <<< "not ok" >>>; 1 => f; -do { <<<"test">>>; } +do { <<< "test" >>>; } until(f); diff --git a/tests/tree/cast_array.gw b/tests/tree/cast_array.gw index cb5f66d5..dc3e3598 100644 --- a/tests/tree/cast_array.gw +++ b/tests/tree/cast_array.gw @@ -1,6 +1,6 @@ typedef int[2] test; test var; -<<>>; -<<>>; -<<>>; -<<>>; +<<< int >>>; +<<< test >>>; +<<< var >>>; +<<< var $ int[] >>>; diff --git a/tests/tree/cast_f2i.gw b/tests/tree/cast_f2i.gw index 923e75d1..e01e8d5a 100644 --- a/tests/tree/cast_f2i.gw +++ b/tests/tree/cast_f2i.gw @@ -1 +1 @@ -<<< (2.0 $ int) >>>; +<<< (2.0 $ int) >>>; diff --git a/tests/tree/cast_test.gw b/tests/tree/cast_test.gw index 3eecbf2a..6bda1429 100644 --- a/tests/tree/cast_test.gw +++ b/tests/tree/cast_test.gw @@ -9,7 +9,7 @@ D d; E e; F f; G g; -//<<>>; -<<< [ f, g ] >>>; -<<>>; -<<>>; +//<<< f $ D >>>; +<<< [ f, g ] >>>; +<<< maybe ? f : D >>>; +<<< c, " ", d, " ", e, " ", g >>>; diff --git a/tests/tree/class_do_until.gw b/tests/tree/class_do_until.gw index bc74ce14..d171733c 100644 --- a/tests/tree/class_do_until.gw +++ b/tests/tree/class_do_until.gw @@ -1,6 +1,6 @@ class C { int i; - do { <<>>; } + do { <<< i++ >>>; } while(i < 6); } diff --git a/tests/tree/class_do_while.gw b/tests/tree/class_do_while.gw index bc74ce14..d171733c 100644 --- a/tests/tree/class_do_while.gw +++ b/tests/tree/class_do_while.gw @@ -1,6 +1,6 @@ class C { int i; - do { <<>>; } + do { <<< i++ >>>; } while(i < 6); } diff --git a/tests/tree/class_dot.gw b/tests/tree/class_dot.gw index bd890aca..829c06bc 100644 --- a/tests/tree/class_dot.gw +++ b/tests/tree/class_dot.gw @@ -6,4 +6,4 @@ class C { } C c; -<<>>; +<<< c.j[1] >>>; diff --git a/tests/tree/class_for.gw b/tests/tree/class_for.gw index 3c857563..d5a4fdb1 100644 --- a/tests/tree/class_for.gw +++ b/tests/tree/class_for.gw @@ -1,5 +1,5 @@ class C { for(int i; i < 3; i++) - <<>>; + <<< i >>>; } diff --git a/tests/tree/class_if_exp.gw b/tests/tree/class_if_exp.gw index 681860d6..fb766190 100644 --- a/tests/tree/class_if_exp.gw +++ b/tests/tree/class_if_exp.gw @@ -1,4 +1,4 @@ class C { - <<>>; + <<< maybe ? "ok" : "not ok" >>>; } diff --git a/tests/tree/class_named_union.gw b/tests/tree/class_named_union.gw index 0e0508d4..7eabcb2a 100644 --- a/tests/tree/class_named_union.gw +++ b/tests/tree/class_named_union.gw @@ -5,26 +5,26 @@ class C { float f; } U; - <<>>; - <<>>; - <<>>; + <<< U >>>; + <<< U.i >>>; + <<< U.f >>>; 12 => U.i; - <<>>; + <<< U.i >>>; 12.3 => U.f; - <<>>; - <<>>; + <<< U.f >>>; + <<< U.i >>>; } C c; -<<>>; -<<>>; -<<>>; -<<>>; +<<< c >>>; +<<< c.U >>>; +<<< c.U.i >>>; +<<< c.U.f >>>; 123 => c.U.i; -<<>>; +<<< c.U.i >>>; 1.23 => c.U.f; -<<>>; -<<>>; -<<>>; +<<< c.U.f >>>; +<<< c.U.i >>>; +<<< c.i >>>; diff --git a/tests/tree/class_repeat.gw b/tests/tree/class_repeat.gw index 2a3c5af2..1530910d 100644 --- a/tests/tree/class_repeat.gw +++ b/tests/tree/class_repeat.gw @@ -2,7 +2,7 @@ class C { int i; repeat(3) { i++; - <<>>; + <<< i >>>; } } diff --git a/tests/tree/class_switch.gw b/tests/tree/class_switch.gw index 78cf31cb..b4389062 100644 --- a/tests/tree/class_switch.gw +++ b/tests/tree/class_switch.gw @@ -1,6 +1,6 @@ class C { int i; - <<>>; + <<< i >>>; switch(i) { 2; case 1: diff --git a/tests/tree/class_template.gw b/tests/tree/class_template.gw index ed469426..ca6b1437 100644 --- a/tests/tree/class_template.gw +++ b/tests/tree/class_template.gw @@ -2,26 +2,26 @@ class<~A,B~> C { A a; B b; fun A test() { - <<<"lol">>>; + <<< "lol" >>>; } fun void test2<~C~>(C c) { - <<>>; + <<< c >>>; } } -//<<>>; +//<<< C >>>; <~int, int~>C c; <~float, int~>C d; <~polar, int~>C e; <~Vec3, int~>C f; <~Object, int~>C g; //C c; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< c.a >>>; +<<< d.a >>>; +<<< e.a >>>; +<<< c.test() >>>; +<<< d.test() >>>; +<<< e.test() >>>; +<<< f.test() >>>; +<<< g.test() >>>; c.test2(2); diff --git a/tests/tree/class_union.gw b/tests/tree/class_union.gw index 73963aab..89962f55 100644 --- a/tests/tree/class_union.gw +++ b/tests/tree/class_union.gw @@ -4,6 +4,6 @@ class C { int one; string @ two; }; - <<>>; + <<< one, " ", two >>>; } diff --git a/tests/tree/const.gw b/tests/tree/const.gw index 5097c57f..30004d1b 100644 --- a/tests/tree/const.gw +++ b/tests/tree/const.gw @@ -1,2 +1,2 @@ 10 => const int i; -<<>>; +<<< i >>>; diff --git a/tests/tree/decl_exp_array.gw b/tests/tree/decl_exp_array.gw index b5049f7c..5d0bd869 100644 --- a/tests/tree/decl_exp_array.gw +++ b/tests/tree/decl_exp_array.gw @@ -1,2 +1,2 @@ -<<<` new int[2] ` i>>>; -<<>>; \ No newline at end of file +<<< ` new int[2] ` i >>>; +<<< i >>>; \ No newline at end of file diff --git a/tests/tree/do_until_break_continue.gw b/tests/tree/do_until_break_continue.gw index 0d7ce05b..ca0bec3f 100644 --- a/tests/tree/do_until_break_continue.gw +++ b/tests/tree/do_until_break_continue.gw @@ -1,5 +1,5 @@ do{ - <<<"'do' loop">>>; + <<< "'do' loop" >>>; if(maybe) break; else continue; diff --git a/tests/tree/empty_vararg.gw b/tests/tree/empty_vararg.gw index 5ab39824..fa873c54 100644 --- a/tests/tree/empty_vararg.gw +++ b/tests/tree/empty_vararg.gw @@ -1,11 +1,11 @@ fun int test(...){ vararg.start; - <<<"test">>>; - <<>>; + <<< "test" >>>; + <<< vararg.i >>>; vararg.end; return 1; } -<<< test() >>>; -<<< test() >>>; -<<<(1, 7) => test>>>; -<<<() => test>>>; +<<< test() >>>; +<<< test() >>>; +<<< (1, 7) => test >>>; +<<< () => test >>>; diff --git a/tests/tree/enum.gw b/tests/tree/enum.gw index 9aeddd54..05b4fa6e 100644 --- a/tests/tree/enum.gw +++ b/tests/tree/enum.gw @@ -1,4 +1,4 @@ enum { zero, one, two, three }; -<<>>; +<<< zero, " ", one, " ", two, " ", three >>>; diff --git a/tests/tree/extend_typedef.gw b/tests/tree/extend_typedef.gw index 0b4ff2bb..4badf3fa 100644 --- a/tests/tree/extend_typedef.gw +++ b/tests/tree/extend_typedef.gw @@ -1,4 +1,4 @@ typedef Object[2] Class; class C extends Class {} C c; -<<>>; +<<< c >>>; diff --git a/tests/tree/f2i_cast.gw b/tests/tree/f2i_cast.gw index ddb179e4..a6ec6d6a 100644 --- a/tests/tree/f2i_cast.gw +++ b/tests/tree/f2i_cast.gw @@ -1,5 +1,5 @@ -<<<"test">>>; -<<< 2.3 $ int >>>; +<<< "test" >>>; +<<< 2.3 $ int >>>; 1 => float f; fun void test(float f){} 1 => test; diff --git a/tests/tree/false.gw b/tests/tree/false.gw index 68550496..838cff46 100644 --- a/tests/tree/false.gw +++ b/tests/tree/false.gw @@ -1,2 +1,2 @@ // always return 0 -<<< false >>>; +<<< false >>>; diff --git a/tests/tree/float_if.gw b/tests/tree/float_if.gw index 41d3b9bc..77e8055d 100644 --- a/tests/tree/float_if.gw +++ b/tests/tree/float_if.gw @@ -1,2 +1,2 @@ (2.0 ? "yeah" : "not yeah") => string s; -<<>>; +<<< s >>>; diff --git a/tests/tree/for.gw b/tests/tree/for.gw index 8b0acef9..3f26fa3b 100644 --- a/tests/tree/for.gw +++ b/tests/tree/for.gw @@ -2,9 +2,9 @@ for(int i; i < 4; i++) { if(i == 2) continue; - <<>>; + <<< i >>>; } for(int i; i < 3;) - <<>>; + <<< i++ >>>; float f; for(1 => f; f; 1 -=>f); diff --git a/tests/tree/fptr_class.gw b/tests/tree/fptr_class.gw index 4b158a4f..cb798c5b 100644 --- a/tests/tree/fptr_class.gw +++ b/tests/tree/fptr_class.gw @@ -1,5 +1,5 @@ class C { - fun void test(int i) { <<< "int arg" >>>; } + fun void test(int i) { <<< "int arg" >>>; } typedef void Ptr(int i); test @=> Ptr p; @@ -8,4 +8,4 @@ class C { p(1); } C c; -<<>>; +<<< c >>>; diff --git a/tests/tree/func_ret_void.gw b/tests/tree/func_ret_void.gw index 88eb7a5d..634ebc49 100644 --- a/tests/tree/func_ret_void.gw +++ b/tests/tree/func_ret_void.gw @@ -1,2 +1,2 @@ -fun void test() { <<<"test">>>; return; <<<"this won't print. ever.">>>; } +fun void test() { <<< "test" >>>; return; <<< "this won't print. ever." >>>; } test(); diff --git a/tests/tree/func_sig_differ.gw b/tests/tree/func_sig_differ.gw index 607fddf7..9c2d5535 100644 --- a/tests/tree/func_sig_differ.gw +++ b/tests/tree/func_sig_differ.gw @@ -1,4 +1,4 @@ fun void test(int i){} fun int test(){} -<<>>; -<<>>; +<<< test(1) >>>; +<<< test() >>>; diff --git a/tests/tree/gc1.gw b/tests/tree/gc1.gw index 93dfbf3b..7b7601c2 100644 --- a/tests/tree/gc1.gw +++ b/tests/tree/gc1.gw @@ -1,3 +1,3 @@ Object o; -<<>>; +<<< o >>>; me.exit(); diff --git a/tests/tree/htol.gw b/tests/tree/htol.gw index 7d3a4fb2..9c09d1b0 100644 --- a/tests/tree/htol.gw +++ b/tests/tree/htol.gw @@ -1,2 +1,2 @@ -<<<0x12aA>>>; -<<<0c23>>>; +<<< 0x12aA >>>; +<<< 0c23 >>>; diff --git a/tests/tree/if_exp.gw b/tests/tree/if_exp.gw index c7a78b14..86f85bc7 100644 --- a/tests/tree/if_exp.gw +++ b/tests/tree/if_exp.gw @@ -1 +1 @@ -<<>>; +<<< maybe ? "ok" : "not ok" >>>; diff --git a/tests/tree/if_obj.gw b/tests/tree/if_obj.gw index a0b64b84..dbdbe897 100644 --- a/tests/tree/if_obj.gw +++ b/tests/tree/if_obj.gw @@ -1,2 +1,2 @@ Object o; -if(o)<<<"ok">>>; +if(o)<<< "ok" >>>; diff --git a/tests/tree/map.gw b/tests/tree/map.gw index 80dce2b7..c224dea1 100644 --- a/tests/tree/map.gw +++ b/tests/tree/map.gw @@ -1,5 +1,5 @@ <~int, int~>Map pp; -<<>>; -<<>>; -<<>>; -<<>>; +<<< pp >>>; +<<< pp.size() >>>; +<<< pp.set(1, 2) >>>; +<<< pp.get(1) >>>; diff --git a/tests/tree/member_op.gw b/tests/tree/member_op.gw index 27ab7e60..3d39b169 100644 --- a/tests/tree/member_op.gw +++ b/tests/tree/member_op.gw @@ -1,6 +1,6 @@ class C { - operator => void(C c, int i){<<>>;} + operator => void(C c, int i){<<< c, " ", i >>>;} // this => this; //fun void test_op(C c){ this => c; } this => int i; diff --git a/tests/tree/multi_decl.gw b/tests/tree/multi_decl.gw index 062fc59b..a5e3908b 100644 --- a/tests/tree/multi_decl.gw +++ b/tests/tree/multi_decl.gw @@ -1,2 +1,2 @@ int i, j; -<<>>; +<<< i, " ", j >>>; diff --git a/tests/tree/multi_ref_decl.gw b/tests/tree/multi_ref_decl.gw index c65d2581..24a15cf4 100644 --- a/tests/tree/multi_ref_decl.gw +++ b/tests/tree/multi_ref_decl.gw @@ -1,2 +1,2 @@ Object @ i, a; -<<>>; +<<< i, a >>>; diff --git a/tests/tree/named_union.gw b/tests/tree/named_union.gw index 1946dd37..6a8c1105 100644 --- a/tests/tree/named_union.gw +++ b/tests/tree/named_union.gw @@ -4,13 +4,13 @@ union { float f; } U; 7.3 => float f; -<<>>; -<<>>; -<<>>; +<<< U >>>; +<<< U.i >>>; +<<< U.f >>>; 12 => U.i; -<<>>; +<<< U.i >>>; 12.3 => U.f; -<<>>; -<<>>; -<<>>; -<<>>; +<<< U.f >>>; +<<< U.i >>>; +<<< i >>>; +<<< f >>>; diff --git a/tests/tree/named_union_private_static.gw b/tests/tree/named_union_private_static.gw index e5db91c9..23df19af 100644 --- a/tests/tree/named_union_private_static.gw +++ b/tests/tree/named_union_private_static.gw @@ -1,4 +1,4 @@ -class C { union static private { int i; } u;<<>>; +class C { union static private { int i; } u;<<< this, " ", u, " ", this.u.i >>>; } C c; -<<>>; +<<< c >>>; diff --git a/tests/tree/named_union_static.gw b/tests/tree/named_union_static.gw index c1229440..6a32149f 100644 --- a/tests/tree/named_union_static.gw +++ b/tests/tree/named_union_static.gw @@ -1,5 +1,5 @@ -class C { union static { int i; } u;<<>>; } +class C { union static { int i; } u;<<< this, " ", u, " ", this.u.i >>>; } C c; -<<>>; -<<>>; -<<>>; +<<< c >>>; +<<< C.u >>>; +<<< C.u.i >>>; diff --git a/tests/tree/nested_switch.gw b/tests/tree/nested_switch.gw index fabddf09..4df0968d 100644 --- a/tests/tree/nested_switch.gw +++ b/tests/tree/nested_switch.gw @@ -1,9 +1,9 @@ switch(maybe) { - case 1: <<<1>>>;break; + case 1: <<< 1 >>>;break; case 0: switch(maybe) { case 1: break; - case 0:<<<0>>>; break; + case 0:<<< 0 >>>; break; } break; } diff --git a/tests/tree/new_array.gw b/tests/tree/new_array.gw index 7c313ed7..b00dc1b5 100644 --- a/tests/tree/new_array.gw +++ b/tests/tree/new_array.gw @@ -1,2 +1,2 @@ -<<>>; +<<< new int[3] >>>; diff --git a/tests/tree/nil.gw b/tests/tree/nil.gw index d648c71d..9099b5ca 100644 --- a/tests/tree/nil.gw +++ b/tests/tree/nil.gw @@ -1 +1 @@ -<<<()>>>; +<<< () >>>; diff --git a/tests/tree/notf.gw b/tests/tree/notf.gw index 6430fff5..12ad8ed8 100644 --- a/tests/tree/notf.gw +++ b/tests/tree/notf.gw @@ -1 +1 @@ -if(!0.0)<<<"ok">>>; +if(!0.0)<<< "ok" >>>; diff --git a/tests/tree/object_func.gw b/tests/tree/object_func.gw index ab3df037..eb60ca7f 100644 --- a/tests/tree/object_func.gw +++ b/tests/tree/object_func.gw @@ -1,2 +1,2 @@ -fun Object test(){ Object o; <<>>; return new Object; } +fun Object test(){ Object o; <<< o >>>; return new Object; } test(); diff --git a/tests/tree/op_eq.gw b/tests/tree/op_eq.gw index 2651992a..0425d5af 100644 --- a/tests/tree/op_eq.gw +++ b/tests/tree/op_eq.gw @@ -1,2 +1,2 @@ -<<<0 == 0>>> +<<< 0 == 0 >>> ; diff --git a/tests/tree/pair.gw b/tests/tree/pair.gw index da9a08c8..61ef1e1f 100644 --- a/tests/tree/pair.gw +++ b/tests/tree/pair.gw @@ -1,9 +1,9 @@ <~float, int~>Pair p; -<<

>>; +<<< p >>>; 1 => p.key; 2 => p.val; -<<>>; +<<< p.key, " ", p.val >>>; (2,3) => p.set; -<<>>; +<<< p.key, " ", p.val >>>; diff --git a/tests/tree/pi.gw b/tests/tree/pi.gw index 44786919..2f5eedb2 100644 --- a/tests/tree/pi.gw +++ b/tests/tree/pi.gw @@ -1 +1 @@ -<<>>; +<<< pi >>>; diff --git a/tests/tree/pre_post_inc_dec.gw b/tests/tree/pre_post_inc_dec.gw index ed612829..f4d89c85 100644 --- a/tests/tree/pre_post_inc_dec.gw +++ b/tests/tree/pre_post_inc_dec.gw @@ -1,9 +1,9 @@ int i; -<<< i++ >>>; -<<< i >>>; -<<< i-- >>>; -<<< i >>>; -<<< ++i >>>; -<<< i >>>; -<<< --i >>>; -<<< i >>>; +<<< i++ >>>; +<<< i >>>; +<<< i-- >>>; +<<< i >>>; +<<< ++i >>>; +<<< i >>>; +<<< --i >>>; +<<< i >>>; diff --git a/tests/tree/private_access.gw b/tests/tree/private_access.gw index 981e10e8..ca794794 100644 --- a/tests/tree/private_access.gw +++ b/tests/tree/private_access.gw @@ -1,3 +1,3 @@ -class C { private int i; <<>>; } +class C { private int i; <<< i >>>; } C c; -<<>>; +<<< c >>>; diff --git a/tests/tree/private_func.gw b/tests/tree/private_func.gw index 00a75fd0..11ca9a33 100644 --- a/tests/tree/private_func.gw +++ b/tests/tree/private_func.gw @@ -4,4 +4,4 @@ class C { } C c; -<<>>; +<<< c >>>; diff --git a/tests/tree/protect.gw b/tests/tree/protect.gw index af1b5178..b317f599 100644 --- a/tests/tree/protect.gw +++ b/tests/tree/protect.gw @@ -1,9 +1,9 @@ class C { protect int i; - <<<++i>>>; + <<< ++i >>>; } C c; -<<>>; -//<<<++c.i>>>; +<<< c.i >>>; +//<<< ++c.i >>>; //1 => c.i; 2 +=> c.i; diff --git a/tests/tree/ptr_decl_assign.gw b/tests/tree/ptr_decl_assign.gw index 6edb9197..08b4fe86 100644 --- a/tests/tree/ptr_decl_assign.gw +++ b/tests/tree/ptr_decl_assign.gw @@ -1,4 +1,4 @@ typedef void Test(); -fun void t(){<<<"lol">>>;} +fun void t(){<<< "lol" >>>;} t @=> Test test; test(); diff --git a/tests/tree/repeat.gw b/tests/tree/repeat.gw index 8fd09188..baf3068c 100644 --- a/tests/tree/repeat.gw +++ b/tests/tree/repeat.gw @@ -1,5 +1,5 @@ int i; repeat(3) { i++; - <<>>; + <<< i >>>; } diff --git a/tests/tree/return_void.gw b/tests/tree/return_void.gw index d23fe444..190b9931 100644 --- a/tests/tree/return_void.gw +++ b/tests/tree/return_void.gw @@ -2,8 +2,8 @@ int i; // define a funs that returns 1 if 'i' is non zero, and 0 othervise. fun int test() { return i ? 1 : 0; } -<<>>; +<<< test() >>>; 1 => i; -<<>>; +<<< test() >>>; 2 => i; -<<>>; +<<< test() >>>; diff --git a/tests/tree/shredule_test.gw b/tests/tree/shredule_test.gw index cfe57afe..29ca5f4b 100644 --- a/tests/tree/shredule_test.gw +++ b/tests/tree/shredule_test.gw @@ -5,5 +5,5 @@ spork { samp => now; 4::samp => now;}; spork { 5::samp => now;} @=> Shred @s; spork { samp => now; 4::samp => now; } @=> Shred @t; spork { 2::samp => now; me.exit(); }; -spork { new Object; <<<"garbage collect me" >>>; 3::samp => now; }; +spork { new Object; <<< "garbage collect me" >>>; 3::samp => now; }; 2::samp => now; diff --git a/tests/tree/simple_assign.gw b/tests/tree/simple_assign.gw index 4ad9910b..66b69889 100644 --- a/tests/tree/simple_assign.gw +++ b/tests/tree/simple_assign.gw @@ -1,2 +1,2 @@ 12 => int i; -<<>>; +<<< i >>>; diff --git a/tests/tree/simple_decl.gw b/tests/tree/simple_decl.gw index 271009cb..9b4ea7b6 100644 --- a/tests/tree/simple_decl.gw +++ b/tests/tree/simple_decl.gw @@ -1,2 +1,2 @@ int i; -<<>>; +<<< i >>>; diff --git a/tests/tree/simple_ref_decl.gw b/tests/tree/simple_ref_decl.gw index 384ac16a..e92148e4 100644 --- a/tests/tree/simple_ref_decl.gw +++ b/tests/tree/simple_ref_decl.gw @@ -1,2 +1,2 @@ Object @ o; -<<>>; +<<< o >>>; diff --git a/tests/tree/sizeof.gw b/tests/tree/sizeof.gw index ce6b26fd..6efcfd5d 100644 --- a/tests/tree/sizeof.gw +++ b/tests/tree/sizeof.gw @@ -1 +1 @@ -<<>>; +<<< sizeof int >>>; diff --git a/tests/tree/spork_in_func.gw b/tests/tree/spork_in_func.gw index 72b71082..b7c589f9 100644 --- a/tests/tree/spork_in_func.gw +++ b/tests/tree/spork_in_func.gw @@ -1,7 +1,7 @@ fun void test() { - spork { <<<2>>>; }; + spork { <<< 2 >>>; }; } -//spork { <<<1>>>; }; +//spork { <<< 1 >>>; }; //spork test(); test(); second => now; diff --git a/tests/tree/spork_member.gw b/tests/tree/spork_member.gw index 192ba5db..1939a9a3 100644 --- a/tests/tree/spork_member.gw +++ b/tests/tree/spork_member.gw @@ -1,16 +1,16 @@ class C { fun void test(int i){ - <<>>; + <<< i >>>; spork { - <<<"test2">>>; + <<< "test2" >>>; }; } // spork test(2); -// spork { <<<"test", this>>>; }; +// spork { <<< "test", this >>>; }; } C c; -<<>>; +<<< c >>>; //spork c.test(1); c.test(2); diff --git a/tests/tree/static_template.gw b/tests/tree/static_template.gw index a7077e0c..6d61f342 100644 --- a/tests/tree/static_template.gw +++ b/tests/tree/static_template.gw @@ -7,5 +7,5 @@ class D { } D d; -<<>>; -<<>>; +<<< d >>>; +<<< D.c.a >>>; diff --git a/tests/tree/string_eq.gw b/tests/tree/string_eq.gw index 5e66f2d9..249b6122 100644 --- a/tests/tree/string_eq.gw +++ b/tests/tree/string_eq.gw @@ -1,4 +1,4 @@ -<<<"test" == "test">>>; +<<< "test" == "test" >>>; string s; -<<>>; -<<<"test" == s>>>; +<<< s == s >>>; +<<< "test" == s >>>; diff --git a/tests/tree/switch.gw b/tests/tree/switch.gw index 39d418cb..9906b706 100644 --- a/tests/tree/switch.gw +++ b/tests/tree/switch.gw @@ -1,5 +1,5 @@ int i; -<<>>; +<<< i >>>; switch(i) { 2; case 1: break; diff --git a/tests/tree/template_class_ref.gw b/tests/tree/template_class_ref.gw index 263cc918..616e0bf5 100644 --- a/tests/tree/template_class_ref.gw +++ b/tests/tree/template_class_ref.gw @@ -1,4 +1,4 @@ class<~A~> C {} <~int~>C ref; -<<>>; +<<< ref >>>; diff --git a/tests/tree/template_typedef.gw b/tests/tree/template_typedef.gw index a1565217..2edaf7f5 100644 --- a/tests/tree/template_typedef.gw +++ b/tests/tree/template_typedef.gw @@ -1,13 +1,13 @@ <~int, int~>Pair p; typedef <~int, int~>Pair lol; lol t; -<<>>; -<<>>; +<<< t >>>; +<<< t.key >>>; class C extends lol { int i;} C c; -<<>>; +<<< c.i >>>; class<~A~> D { - <<<"lol">>>; + <<< "lol" >>>; int i; } typedef <~int~>D Lol; @@ -15,6 +15,6 @@ class E extends Lol { float f; } E d; -<<>>; -<<>>; -<<>>; +<<< d >>>; +<<< d.i >>>; +<<< d.f >>>; diff --git a/tests/tree/this_valid.gw b/tests/tree/this_valid.gw index a526f220..54bb94b5 100644 --- a/tests/tree/this_valid.gw +++ b/tests/tree/this_valid.gw @@ -1,7 +1,7 @@ class C { fun void test() { - <<>>; + <<< this >>>; } } diff --git a/tests/tree/uncalled_functions.gw b/tests/tree/uncalled_functions.gw index 79c3ebfe..0157635a 100644 --- a/tests/tree/uncalled_functions.gw +++ b/tests/tree/uncalled_functions.gw @@ -17,15 +17,15 @@ C.stest; e.signal; Shred.fromId; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< c.test >>>; +<<< C.stest >>>; +<<< e.signal >>>; +<<< Shred.fromId >>>; +<<< c.test >>>; +<<< C.stest >>>; +<<< e.signal >>>; +<<< Shred.fromId >>>; +<<< c.test >>>; +<<< C.stest >>>; +<<< e.signal >>>; +<<< Shred.fromId >>>; diff --git a/tests/tree/union.gw b/tests/tree/union.gw index 0654444b..92af3a6e 100644 --- a/tests/tree/union.gw +++ b/tests/tree/union.gw @@ -3,4 +3,4 @@ union int one; string @ two; }; -<<>>; +<<< one, " ", two >>>; diff --git a/tests/tree/usr_unary.gw b/tests/tree/usr_unary.gw index 0c31266b..8d60035c 100644 --- a/tests/tree/usr_unary.gw +++ b/tests/tree/usr_unary.gw @@ -1,9 +1,9 @@ class C { int i; } ++ operator int (C c) { - <<<"test">>>; - <<>>; - <<<++c.i>>>; + <<< "test" >>>; + <<< c >>>; + <<< ++c.i >>>; } C c; -<<>>; +<<< c >>>; ++c;

>>; +<<< test >>>; +//<<< ti >>>; +<<< p >>>; //ti(); -<<<"test">>>; +<<< "test" >>>; p(2); -<<<"end">>>; +<<< "end" >>>; Callback.callback(p, 6); diff --git a/tests/import/class_template.gw b/tests/import/class_template.gw index 245aca58..24a29c2c 100644 --- a/tests/import/class_template.gw +++ b/tests/import/class_template.gw @@ -3,13 +3,13 @@ //class C{ A key; B value; } //<~int, int~>C c1; //C c2; -//<<>>; -//<<>>; -//<<>>; +//<<< c1 >>>; +//<<< c2 >>>; +//<<< c2.value >>>; <~int, int~>ClassTemplate ct; -<<>>; +<<< ct.key >>>; //ClassTemplate ct2; -//<<>>; +//<<< ct2.key >>>; //ClassTemplate ct3; -//<<>>; +//<<< ct3.key >>>; diff --git a/tests/import/coverage.gw b/tests/import/coverage.gw index da2b3ed9..c0773f94 100644 --- a/tests/import/coverage.gw +++ b/tests/import/coverage.gw @@ -1,26 +1,26 @@ -<<>>; +<<< float f >>>; Coverage c; c.s_i; -<<< Coverage.i() >>>; -<<< Coverage.f() >>>; -<<< Coverage.c() >>>; -<<< Coverage.v() >>>; -<<< Coverage.w() >>>; +<<< Coverage.i() >>>; +<<< Coverage.f() >>>; +<<< Coverage.c() >>>; +<<< Coverage.v() >>>; +<<< Coverage.w() >>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< Coverage.s_i >>>; +<<< Coverage.s_f >>>; +<<< Coverage.s_c >>>; +<<< Coverage.s_v >>>; +<<< Coverage.s_w >>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< Coverage.sc_i >>>; +<<< Coverage.sc_f >>>; +<<< Coverage.sc_c >>>; +<<< Coverage.sc_v >>>; +<<< Coverage.sc_w >>>; -<<< 1 => Coverage.s_i >>>; -<<< 1.2 => Coverage.s_f >>>; -<<< #(1.2, 0.1) => Coverage.s_c >>>; -<<< @(1.2, 0.1, 2.6) => Coverage.s_v >>>; -<<< @(1.2, 0.1, 2.6, 4.6) => Coverage.s_w >>>; +<<< 1 => Coverage.s_i >>>; +<<< 1.2 => Coverage.s_f >>>; +<<< #(1.2, 0.1) => Coverage.s_c >>>; +<<< @(1.2, 0.1, 2.6) => Coverage.s_v >>>; +<<< @(1.2, 0.1, 2.6, 4.6) => Coverage.s_w >>>; diff --git a/tests/import/enum.gw b/tests/import/enum.gw index 85666650..368151d5 100644 --- a/tests/import/enum.gw +++ b/tests/import/enum.gw @@ -1,48 +1,48 @@ // untyped global enum -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< ENUM0 >>>; +<<< ENUM1 >>>; +<<< ENUM2 >>>; +<<< ENUM3 >>>; +<<< ENUM4 >>>; +<<< ENUM5 >>>; +<<< ENUM6 >>>; +<<< ENUM7 >>>; +<<< ENUM8 >>>; +<<< ENUM9 >>>; // typed global enum -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< TYPED_ENUM0 >>>; +<<< TYPED_ENUM1 >>>; +<<< TYPED_ENUM2 >>>; +<<< TYPED_ENUM3 >>>; +<<< TYPED_ENUM4 >>>; +<<< TYPED_ENUM5 >>>; +<<< TYPED_ENUM6 >>>; +<<< TYPED_ENUM7 >>>; +<<< TYPED_ENUM8 >>>; +<<< TYPED_ENUM9 >>>; // in class // untyped global enum -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< Enum.ENUM0 >>>; +<<< Enum.ENUM1 >>>; +<<< Enum.ENUM2 >>>; +<<< Enum.ENUM3 >>>; +<<< Enum.ENUM4 >>>; +<<< Enum.ENUM5 >>>; +<<< Enum.ENUM6 >>>; +<<< Enum.ENUM7 >>>; +<<< Enum.ENUM8 >>>; +<<< Enum.ENUM9 >>>; // Enum.typed global enum -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; -<<>>; +<<< Enum.TYPED_ENUM0 >>>; +<<< Enum.TYPED_ENUM1 >>>; +<<< Enum.TYPED_ENUM2 >>>; +<<< Enum.TYPED_ENUM3 >>>; +<<< Enum.TYPED_ENUM4 >>>; +<<< Enum.TYPED_ENUM5 >>>; +<<< Enum.TYPED_ENUM6 >>>; +<<< Enum.TYPED_ENUM7 >>>; +<<< Enum.TYPED_ENUM8 >>>; +<<< Enum.TYPED_ENUM9 >>>; diff --git a/tests/import/extend_array.gw b/tests/import/extend_array.gw index a3aa9702..125a9fd5 100644 --- a/tests/import/extend_array.gw +++ b/tests/import/extend_array.gw @@ -1,3 +1,3 @@ ArrayExt a; -<<>>; -<<>>; +<<< a >>>; +<<< a.size() >>>; diff --git a/tests/import/extend_event.gw b/tests/import/extend_event.gw index b4c6647e..e34bf66c 100644 --- a/tests/import/extend_event.gw +++ b/tests/import/extend_event.gw @@ -1,2 +1,2 @@ Ev ev; -<<>>; +<<< ev >>>; diff --git a/tests/import/extend_pair.gw b/tests/import/extend_pair.gw index f32763dc..aea25560 100644 --- a/tests/import/extend_pair.gw +++ b/tests/import/extend_pair.gw @@ -1,4 +1,4 @@ <~int, int~>PairExt p; -<<