Add built-in functions
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This is a good proxy test to ensure that scope queries work correctly.
This commit is contained in:
parent
073ff80adb
commit
2d89ec8b20
2 changed files with 26 additions and 0 deletions
19
test/highlight/built-ins.tig
Normal file
19
test/highlight/built-ins.tig
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
let
|
||||
var a := exit(0)
|
||||
/* ^ function.builtin */
|
||||
|
||||
primitive exit(ret: int) /* Shadowing the prelude-included built-in */
|
||||
|
||||
var b := exit(0)
|
||||
/* ^ function */
|
||||
|
||||
in
|
||||
exit(1);
|
||||
/* <- function */
|
||||
|
||||
print("shadowing is fun");
|
||||
/* <- function.builtin */
|
||||
|
||||
b := print
|
||||
/* ^ variable */
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue