fun void test() { <<< "member function." >>>; }
class C {
typedef void func_t();
-// typedef static void s_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;
+#! 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." >>>; }
-// test @=> func_p;
-// test @=> s_ptr;
+#! fun static void s_test() { <<< "member fun." >>>; }
+#! test @=> func_p;
+#! test @=> s_ptr;
-// those are forbidden
-//func_p();
-//this.func_p();
+#! those are forbidden
+#!func_p();
+#!this.func_p();
test2 @=> func_p;
-//func_p();
+#!func_p();
test();
-//<<< test >>>;//, func_p >>>;
+#!<<< test >>>;//, func_p >>>;
}
C c;
c.func_p();
-//test @=> c.s_func_p;
+#!test @=> c.s_func_p;
c.test @=> c.func_p;
c.func_p();
c.test2 @=> c.func_p;
Event e;
spork {second => now; e.broadcast(); };
spork \{second => now; e.broadcast(); }();
-//2::second => now;
+#!2::second => now;
.2::second => now;
e => now;
static Event e;
}
second => now;
-//second => now;
+#!second => now;
<<< "base ", me >>>;
-//TestEvent.e => now;
+#!TestEvent.e => now;
<<< "ok" >>>;
second => now;
Machine.add("examples/int.gw");
Machine.compile("int i;<<< 120 >>>;");
-//Machine.compile("int i[error];");
+#!Machine.compile("int i[error];");
<<< Machine.check("12 => int i; <<< i >>>") >>>;
Machine.check("int i[error];");
C c;
C d;
-//me.yield();
+#!me.yield();
<<< "end of dtor test." >>>;
<<< c," ", d >>>;
-// coverage for 'float'. (generated by util/coverage.sh)
+#! coverage for 'float'. (generated by util/coverage.sh)
float a;
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1=variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1+variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1-variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1*variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1/variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1&&variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1||variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1==variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1!=variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1>variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1>=variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1<variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1<=variable2 >>>;
}
-//testing operator for and float
+#!testing operator for and float
{
float variable2;
<<< -variable2 >>>;
}
-//testing operator for and int
+#!testing operator for and int
{
int variable2;
<<< !variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1=>variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1+=>variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1-=>variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
float variable1;
float variable2;
<<< variable1*=>variable2 >>>;
}
-//testing operator for float and float
+#!testing operator for float and float
{
1 => float variable1;
1 => float variable2;
<<< variable1/=>variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1=variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1+variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1-variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1*variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1/variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1&&variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1||variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1==variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1!=variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1>variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1>=variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1<variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1<=variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1=>variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1+=>variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1-=>variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
float variable2;
<<< variable1*=>variable2 >>>;
}
-//testing operator for int and float
+#!testing operator for int and float
{
int variable1;
1 => float variable2;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1=variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1+variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1-variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1/variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1&&variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1||variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1==variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1!=variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1>variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1>=variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1<variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1<=variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1=>variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1+=>variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1-=>variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
float variable1;
int variable2;
<<< variable1*=>variable2 >>>;
}
-//testing operator for float and int
+#!testing operator for float and int
{
1 => float variable1;
1 => int variable2;
-// define a fun pointer type
+#! define a fun pointer type
typedef void Test()
-// define a few funs
+#! define a few funs
fun void test1(){ <<< "test" >>>; };
fun void test2(){ <<< "another test" >>>; };
fun void test3(){ <<< "yet another test" >>>; };
-// create a fun pointer instance
+#! create a fun pointer instance
Test test;
-// assign it a fun
+#! assign it a fun
test1 @=> test;
-// test it
+#! test it
test();
-// ...
+#! ...
test2 @=> test;
test();
-// coverage for 'int'. (generated by util/coverage.sh)
+#! coverage for 'int'. (generated by util/coverage.sh)
int a;
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1=variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1+variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1-variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1*variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
1 => int variable2;
<<< variable1/variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
1 => int variable2;
<<< variable1%variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1&&variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1||variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1==variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1!=variable2 >>>;
}
-//testing operator for Object and
+#!testing operator for Object and
{
Object @variable1;
<<< variable1!= null >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1>=variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1<variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1<=variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1>>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1<<variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1&variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1|variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1^variable2 >>>;
}
-//testing operator for and int
+#!testing operator for and int
{
int variable2;
<<< -variable2 >>>;
}
-//testing operator for and int
+#!testing operator for and int
{
int variable2;
<<< !variable2 >>>;
}
-//testing operator for int and
+#!testing operator for int and
{
int variable1;
<<< variable1++ >>>;
}
-//testing operator for and int
+#!testing operator for and int
{
int variable2;
<<< ++variable2 >>>;
}
-//testing operator for int and
+#!testing operator for int and
{
int variable1;
<<< variable1-- >>>;
}
-//testing operator for and int
+#!testing operator for and int
{
int variable2;
<<< --variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1+=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1-=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1*=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
1 => int variable1;
1 => int variable2;
<<< variable1/=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
1 => int variable1;
int variable2;
<<< variable1%=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1<<=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1>>=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1&=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1|=>variable2 >>>;
}
-//testing operator for int and int
+#!testing operator for int and int
{
int variable1;
int variable2;
<<< variable1^=>variable2 >>>;
}
-// testing cmp
+#! testing cmp
~1;
<<< Math.sgn(-1.0) >>>;
<<< Math.hypot(4,5) >>>;
-// sin
+#! sin
<<< Math.sin(1) >>>;
<<< Math.sin(1.0) >>>;
<<< Math.sinh(1) >>>;
<<< Math.asinh(1) >>>;
<<< Math.asinh(1.0) >>>;
-// cos
+#! cos
<<< Math.cos(1) >>>;
<<< Math.cos(1.0) >>>;
<<< Math.cosh(1) >>>;
<<< Math.acosh(1) >>>;
<<< Math.acosh(1.0) >>>;
-// tan
+#! tan
<<< Math.tan(1) >>>;
<<< Math.tan(1.0) >>>;
<<< Math.tanh(1) >>>;
}
C c;
-// read members
+#! read members
<<< c.i, c.c, c.f, c.v, c.w, c.o >>>;
-// call fun members
+#! call fun members
<<< c.m_i(), " ", c.m_f(), " ", c.m_c(), " ",
c.m_v(), " ", c.m_w(), " ", c.m_o() >>>;
-// write members
+#! write members
<<< 12 => c.i >>>;
<<< 1.2 => c.f >>>;
<<< #(0.1, 2.3) => c.c >>>;
-//! test operator
+#!! test operator
operator => void (Object o, int i) {
<<< o, " ", i, " success" >>>;
Object @ref;
}
-//! assign object to C.ref
+#!! assign object to C.ref
operator => void (Object o, C c) {
o @=> c.ref;
<<< "success" >>>;
}
-//operator int plusplus(null d, int i){}
+#!operator int plusplus(null d, int i){}
int i;
Object o;
<<< o, " ", i >>>;
12 => i;
-//o => i;
+#!o => i;
C c;
o => c;
<<< "arg ", i, me.arg(i) >>>;
<<< me.dir(), " ", me.path() >>>;
<<< me.code_dir(), " ", me.code_path() >>>;
-//me.exit();
-// call to non existant arg
+#!me.exit();
+#! call to non existant arg
<<< me.arg(-1) >>>;
fun static Object _o() { return o; }
}
-// read members
+#! read members
<<< C.i, C.c, C.f, C.v, C.w, C.o >>>;
-// call fun members
+#! call fun members
<<< C._i(), " ", C._f(), " ", C._c(), " ", C._v(), " ", C._w(), " ", C._o() >>>;
-// write members
+#! write members
<<< 12 => C.i >>>;
<<< 1.2 => C.f >>>;
<<< #(0.1, 2.3) => C.c >>>;
<<< "su".replace(1, "t") >>>;
<<< "su".replace(1, 2, "turlututu") >>>;
<<< " su ".charAt(1, 'n') >>>;
-//null @=> s;
+#!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
+<<< "test" => s >>>; #! new
+<<< "test" => s >>>; #! new
<<< s >>>;
-<<< null => s >>>; //test me
+<<< null => s >>>; #!test me
<<< o => s >>>;
<<< o >>>;
-// look at me!!!
-<<< o => s >>>; // hang . grrr ...
-<<< "test" + "another test" >>>; // mem leak
+#! look at me!!!
+<<< o => s >>>; #! hang . grrr ...
+<<< "test" + "another test" >>>; #! mem leak
<<< "1".toInt() >>>;
<<< "1".toFloat() >>>;
-//me.exit();
+#!me.exit();
{ (1 + s) @=> string @str; }
{ (2.0 +s) @=> string @str; }
{ (%(2,1) + s) @=> string @str; }
{ (@(2,1, 0) + s) @=> string @str; }
{ (@(2,1, 0, -1) + s) @=> string @str; }
-//{ ("test" + s) @=> string @str; } // leak
+#!{ ("test" + s) @=> string @str; } // leak
<<< 11 +=> 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" + s >>>; #! also leak
+<<< null +=> s >>>; #! also hang
+<<< "test" +=> s >>>; #! test me
<<< "test" == "test" >>>;
<<< "test" != "test" >>>;
<<< "test" == "test1" >>>;
}
2 => i => test;
-//1 => i => test;
-//0 => i => test;
+#!1 => i => test;
+#!0 => i => test;
fun void test(int i) {
if(i == 2)return;
-// if(i == 0)return;
+#! if(i == 0)return;
<<< i >>>;
return test(--i + 3 - 4);
}
-//int i[];
+#!int i[];
typedef int[2] lol;
class C extends lol { }
C c;
UGen @u;
-#!u.last(); // should fail => fails.
+#!u.last(); #! should fail => fails.
SinOsc s => Gain g => dac;
for(-1 => int i;i < 6; i++)
i => g.op;