got type system working
This commit is contained in:
@@ -1,11 +1,6 @@
|
||||
fn main(): String {
|
||||
let a = 2;
|
||||
a;
|
||||
a = 3;
|
||||
a = if(true) {"asdf"} else {"fdsa"};
|
||||
a.b.c.d();
|
||||
a = (b + c.d()); // comment
|
||||
return a.b() ;
|
||||
let a = "asdf";
|
||||
return a ;
|
||||
}
|
||||
|
||||
type User struct {
|
||||
@@ -23,7 +18,7 @@ impl TestTrait for User {
|
||||
return Self{id: id};
|
||||
}
|
||||
fn instance_method(self: Self): i64 {
|
||||
return self.get_id();
|
||||
return self.id;
|
||||
}
|
||||
fn default_impl(self: Self): i64 {
|
||||
return self.instance_method();
|
||||
|
||||
Reference in New Issue
Block a user