|
|
1.1 moko 1: @main[]
2:
3: $a[ $.v1[1] $.v2[2] $.v3[3] ]
4: $b[^test::create[]]
5:
1.5 ! moko 6: $c[$b]
! 7:
1.1 moko 8: ^reflection:copy[$a;$b]
1.5 ! moko 9:
! 10: Object uid: ^reflection:uid[$b]
! 11: Same uid: ^reflection:uid[$c]
! 12:
! 13: $str[value] $c[$str]
! 14: String uid: ^reflection:uid[$str]
1.4 moko 15: Same uid: ^reflection:uid[$c]
1.1 moko 16:
17: Object b:
18: ^print[^hash::create[$b]]
19:
20: ^reflection:copy[$b;$a]
21:
22: Hash a:
23: ^print[$a]
24:
1.3 moko 25: $string[string]
1.1 moko 26: ^try_catch{
27: ^reflection:copy[$string;$a]
28: }
29: ^try_catch{
1.2 moko 30: ^reflection:copy[$a;$string]
1.1 moko 31: }
32:
33: @print[hash]
34: ^hash.foreach[k;v]{$k = $v
35: }
36:
37: @try_catch[code]
38: ^try{
39: $code
40: }{
41: $exception.handled(true)
42: $exception.source
43: $exception.comment
44: }
45:
46: @CLASS
47: test
48:
49: @create[]
50: $v2[3]
51:
52: @SET_v3[value]
53: $another3[=$value=]