Merge: doc: fixed some typos and other misc. corrections
[nit.git] / tests / test_advice_repeated_types.nit
1 # This file is part of NIT ( http://www.nitlanguage.org ).
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 # http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 class A
16 var a: Object
17 fun b(b1: Int) is abstract
18 fun c(c1: Int, c2: Int) is abstract
19 fun d: Object is abstract
20 fun e(e1: Int): Object is abstract
21 end
22
23 class B
24 super A
25
26 redef var a
27 redef fun b(b1) do end
28 redef fun c(c1, c2) do end
29 redef fun d do return ""
30 redef fun e(e1) do return ""
31 end
32
33 class C
34 super A
35
36 redef var a: Object
37 redef fun b(b1: Int) do end
38 redef fun c(c1: Int, c2: Int) do end
39 redef fun d: Object do return ""
40 redef fun e(e1: Int): Object do return ""
41 end
42
43 class D
44 super A
45
46 redef fun b(b1) do end
47 redef fun c(c1, c2) do end
48 redef fun d: Int do return 1
49 redef fun e(e1: Int): Numeric do return 1
50 end
51
52 class E
53 super A
54
55 redef var d: Int = 1
56 end