-Subproject commit d43d59831983e1851205c888a493d09910c8d7c8
+Subproject commit bcd1d80e986e043508e8cab4d29356ecaea3fcd8
var int i;
var float f;
var Object o;
- operator @dtor void () { <<< "dtor" >>>; }
+ operator void @dtor () { <<< "dtor" >>>; }
}
var C c;
class C
{
- operator @dtor void () {<<< 1 >>>;}
+ operator void @dtor () {<<< 1 >>>;}
}
var C c;
#!! test operator
-operator => void (Object o, int i) {
+operator void => (Object o, int i) {
<<< o, " ", i, " success" >>>;
}
}
#!! assign object to C.ref
-operator => void (Object o, C c) {
+operator void => (Object o, C c) {
o @=> c.ref_object;
<<< "success" >>>;
}
var 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 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 => 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;}
var C c, d;
var int i;
}
-operator ++ int (C c) {
+operator int ++ (C c) {
<<< "here" >>>;
<<< c.i++ >>>;
}
#!! a fun
fun void test() {}
#!! operator
- operator => void(C c, C d){
+ operator void => (C c, C d){
<<< c, " ", d >>>;
}
}
class C {
0 => var int i;
}
-operator @implicit int(C c) {
+operator int @implicit (C c) {
return c;
}
10 => var int i;
}
-operator @conditionnal int(C c) {
+operator int @conditionnal (C c) {
<<< __func__ >>>;
--c.i;
return c.i;
#! [contains] must not have args
class C {
- operator @dtor void(int i) {}
+ operator void @dtor (int i) {}
}
#! [contains] must return
class C {
- operator @dtor int() {}
+ operator int @dtor () {}
}
#! [contains] '@dtor' must be in class def!!
-operator @dtor void () {}
+operator void @dtor () {}
12 => var int i;
}
-operator @implicit int (C c) {
+operator int @implicit (C c) {
return c.i;
}
class C {
- operator @gack void() { <<< __func__ >>>; }
+ operator void @gack () { <<< __func__ >>>; }
}
<<< var C c >>>;
<<< c >>>;
#! [contains] must return
-operator @conditionnal Object (int i) {}
+operator Object @conditionnal (int i) {}
10 => var int i;
}
-operator @unconditionnal int(C c) {
+operator int @unconditionnal (C c) {
<<< __func__ >>>;
--c.i;
return !c.i;
#! [contains] must have one
-operator @implicit int(int i, int i) {}
+operator int @implicit (int i, int i) {}
class C:[A] {
- operator @dtor void () { <<< __func__ >>>; }
+ operator void @dtor () { <<< __func__ >>>; }
}
class D:[A] extends C:[A] {
- operator @dtor void () { <<< __func__ >>>; }
+ operator void @dtor () { <<< __func__ >>>; }
}
class E extends D:[int] {
- operator @dtor void () { <<< __func__ >>>; }
+ operator void @dtor () { <<< __func__ >>>; }
}
var E e;
class C:[A] extends U:[A] {
fun void test() { <<< this >>>; }
- operator @dtor void () { <<< __func__ >>>; }
+ operator void @dtor () { <<< __func__ >>>; }
}
var C:[float] c;
struct S {
13 => var int i;
- operator @gack void() { <<< "test", i >>>; }
+ operator void @gack () { <<< "test", i >>>; }
<<< this >>>;
}
class C
{
- operator => void(C c, int i){<<< c, " ", i >>>;}
+ operator void => (C c, int i){<<< c, " ", i >>>;}
#! this => this;
#!fun void test_op(C c){ this => c; }
this => var int i;
<<< 1 + 2 >>>;
#! define and operator
-operator $@+-*%~<>^&!= void (int i, int j) { <<< i, " ", j >>>; }
+operator void $@+-*%~<>^&!= (int i, int j) { <<< i, " ", j >>>; }
1 $@+-*%~<>^&!= 2;
var int i;
}
-++ operator int (C c) {
+operator ++ int (C c) {
<<< "test" >>>;
<<< c >>>;
<<< ++c.i >>>;