2022-06-04 21:27:09 +02:00
|
|
|
let
|
|
|
|
class A extends Object {}
|
|
|
|
/* <- keyword */
|
|
|
|
/* ^ keyword */
|
2022-06-04 21:31:43 +02:00
|
|
|
/* ^ type.builtin */
|
2022-06-04 21:27:09 +02:00
|
|
|
|
|
|
|
type B = class extends A {
|
|
|
|
/* ^ keyword */
|
|
|
|
/* ^ keyword */
|
|
|
|
/* ^ type */
|
|
|
|
|
|
|
|
var a := 12
|
|
|
|
|
|
|
|
method meth() : int = self.a
|
2022-06-04 21:35:31 +02:00
|
|
|
/* <- keyword.method */
|
2022-06-04 21:29:27 +02:00
|
|
|
/* ^ method */
|
2022-06-04 21:38:21 +02:00
|
|
|
/* ^ variable.builtin */
|
2022-06-04 21:27:09 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
var object := new B
|
2022-06-04 21:35:14 +02:00
|
|
|
/* ^ keyword.constructor */
|
2022-06-04 21:27:09 +02:00
|
|
|
in
|
|
|
|
object.a := 27;
|
|
|
|
/* ^ property */
|
2022-06-04 21:29:27 +02:00
|
|
|
|
|
|
|
object.meth()
|
|
|
|
/* ^ method */
|
2022-06-04 21:27:09 +02:00
|
|
|
end
|