mirror of
https://github.com/AleoHQ/leo.git
synced 2024-12-30 05:02:04 +03:00
19 lines
240 B
Plaintext
19 lines
240 B
Plaintext
/*
|
|
namespace: Compile
|
|
expectation: Pass
|
|
*/
|
|
|
|
circuit Foo {
|
|
f: u32;
|
|
|
|
function bar(self) -> u32 {
|
|
return self.f;
|
|
}
|
|
}
|
|
|
|
function main() {
|
|
const a = Foo { f: 1u32 };
|
|
const b = a.bar();
|
|
|
|
console.assert(b == 1u32);
|
|
} |