nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge: rosetta_code: sha1
[nit.git]
/
tests
/
base_attr_def.nit
diff --git
a/tests/base_attr_def.nit
b/tests/base_attr_def.nit
index
1b7474d
..
ecab175
100644
(file)
--- a/
tests/base_attr_def.nit
+++ b/
tests/base_attr_def.nit
@@
-16,7
+16,7
@@
import end
import end
-class Object
+interface Object
end
class Int
end
class Int
@@
-24,15
+24,16
@@
class Int
end
class Foo
end
class Foo
- readable writable var _a1: Int
- readable writable var _a2: Int
+ var a1: Int
+ var a2: Int
fun run
do
a1.output
a2.output
end
fun run
do
a1.output
a2.output
end
- init
+ init is
+ old_style_init
do
a1 = 1
a2 = 2
do
a1 = 1
a2 = 2
@@
-41,7
+42,7
@@
end
class Bar
super Foo
class Bar
super Foo
- readable writable var _a3: Int
+ var a3: Int
redef fun run
do
a1.output
redef fun run
do
a1.output
@@
-49,7
+50,8
@@
class Bar
a3.output
end
a3.output
end
- init
+ init is
+ old_style_init
do
a1 = 10
a2 = 20
do
a1 = 10
a2 = 20