fix(tiger): adjust invalid queries

This commit is contained in:
Bruno BELANYI 2022-06-14 20:01:12 +02:00 committed by Stephan Seitz
parent 6e3f888dc7
commit b8e3b03748
9 changed files with 41 additions and 36 deletions

View file

@ -6,7 +6,7 @@ let
/* ^ type.builtin */
var b := exit(0)
/* ^ function */
/* ^ function.builtin */
type int = string /* Shadowing the built-in type */
/* ^ type.builtin */
@ -30,13 +30,13 @@ in
end;
exit(1);
/* <- function */
/* <- function.builtin */
print("shadowing is fun");
/* <- function.builtin */
self;
/* <- variable */
/* <- variable.builtin */
b := print
/* ^ variable */

View file

@ -1,8 +1,8 @@
primitive print(s: string)
/* ^ function */
/* ^ variable.parameter */
/* ^ parameter */
function func(a: int) : int = (print("Hello World!"); a)
/* ^ function */
/* ^ variable.parameter */
/* ^ function */
/* ^ parameter */
/* ^ function.builtin */

View file

@ -22,8 +22,8 @@ var array := int_array[12] of 27;
/* ^ type */
primitive func(a: int, b: string) : array
/* ^ variable.parameter */
/* ^ parameter */
/* ^ type.builtin */
/* ^ variable.parameter */
/* ^ parameter */
/* ^ type.builtin */
/* ^ type */

View file

@ -1,3 +1,3 @@
import "lib.tih"
/* <- keyword */
/* ^ string.special.path */
/* ^ string.special */

View file

@ -28,13 +28,13 @@ in
/* ^ keyword */
for i := 12 to 27 do 42;
/* <- keyword.repeat */
/* ^ keyword.repeat */
/* ^ keyword.repeat */
/* <- repeat */
/* ^ repeat */
/* ^ repeat */
while 12 do break
/* <- keyword.repeat */
/* ^ keyword.repeat */
/* <- repeat */
/* ^ repeat */
/* ^ keyword */
end

View file

@ -12,13 +12,13 @@ let
var a := 12
method meth() : int = self.a
/* <- keyword.method */
/* <- method */
/* ^ method */
/* ^ variable.builtin */
}
var object := new B
/* ^ keyword.constructor */
/* ^ constructor */
in
object.a := 27;
/* ^ property */