Fixed -tok, spacings in -st, and validation tests

This commit is contained in:
Scarlett
2025-04-16 11:44:02 -04:00
parent b023ac0133
commit 5a23ef2756
26 changed files with 677 additions and 477 deletions

View File

@ -0,0 +1,34 @@
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
test : 001001 : : undefined : Function Definition
main : 001001 : : rec -> integer : Type of Function
rec : 001001 : : Record Type : elements-2 size-8 bytes
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
b : 005000 : 001001 : Boolean : Primitive Instance
x : 005000 : 001001 : integer : Primitive Instance
arg : 005000 : 001001 : integer : Primitive Instance
undefined : 005000 : 001001 : integer : Primitive Instance
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 023009 : 005000 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 021014 : 005000 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 017009 : 005000 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 015017 : 005000 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 011012 : 005000 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 007015 : 005000 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
y : 001000 : 001001 : integer : Primitive Instance
x : 001000 : 001001 : integer : Primitive Instance

View File

@ -1,17 +1,20 @@
NAME : SCOPE : PARENT : TYPE : Extra annotation
-------------------------:--------:--------:--------------------------:------------------------------
entry : 001001 : : main : User Defined
main : 001001 : : primitive function type : User Defined
integer : 001001 : : Primitive : size-4 bytes
address : 001001 : : Primitive : size-8 bytes
character : 001001 : : Primitive : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive : size-1 bytes
-------------------------:--------:--------:--------------------------:------------------------------
b1 : 005000 : 001001 : Boolean : User Defined
b2 : 005000 : 001001 : Boolean : User Defined
arr2 : 005000 : 001001 : address : User Defined
arr : 005000 : 001001 : address : User Defined
x : 005000 : 001001 : integer : User Defined
arg : 005000 : 001001 : string : User Defined
-------------------------:--------:--------:--------------------------:------------------------------
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
entry : 001001 : : undefined : Function Definition
main : 001001 : : string -> integer : Type of Function
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
b1 : 004000 : 001001 : Boolean : Primitive Instance
b2 : 004000 : 001001 : Boolean : Primitive Instance
arr2 : 004000 : 001001 : address : Primitive Instance
arr : 004000 : 001001 : address : Primitive Instance
x : 004000 : 001001 : integer : Primitive Instance
arg : 004000 : 001001 : string : Array Instance

View File

@ -1,17 +1,20 @@
NAME : SCOPE : PARENT : TYPE : Extra annotation
-------------------------:--------:--------:--------------------------:------------------------------
entry : 001001 : : main : User Defined
main : 001001 : : primitive function type : User Defined
integer : 001001 : : Primitive : size-4 bytes
address : 001001 : : Primitive : size-8 bytes
character : 001001 : : Primitive : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive : size-1 bytes
-------------------------:--------:--------:--------------------------:------------------------------
b1 : 005000 : 001001 : Boolean : User Defined
b2 : 005000 : 001001 : Boolean : User Defined
arr2 : 005000 : 001001 : address : User Defined
arr : 005000 : 001001 : address : User Defined
x : 005000 : 001001 : integer : User Defined
arg : 005000 : 001001 : string : User Defined
-------------------------:--------:--------:--------------------------:------------------------------
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
entry : 001001 : : undefined : Function Definition
main : 001001 : : string -> integer : Type of Function
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
b1 : 004000 : 001001 : Boolean : Primitive Instance
b2 : 004000 : 001001 : Boolean : Primitive Instance
arr2 : 004000 : 001001 : address : Primitive Instance
arr : 004000 : 001001 : address : Primitive Instance
x : 004000 : 001001 : integer : Primitive Instance
arg : 004000 : 001001 : string : Array Instance

View File

@ -1,17 +1,20 @@
NAME : SCOPE : PARENT : TYPE : Extra annotation
-------------------------:--------:--------:--------------------------:------------------------------
a_of_s : 001001 : : 1 -> string : Type of Array
string : 001001 : : 1 -> character : Type of Array
entry : 001001 : : main : User Defined
main : 001001 : : primitive function type : User Defined
integer : 001001 : : Primitive : size-4 bytes
address : 001001 : : Primitive : size-8 bytes
character : 001001 : : Primitive : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive : size-1 bytes
-------------------------:--------:--------:--------------------------:------------------------------
many_names : 010000 : 001001 : a_of_s : User Defined
another_name : 010000 : 001001 : string : User Defined
one_name : 010000 : 001001 : string : User Defined
arg : 010000 : 001001 : string : User Defined
-------------------------:--------:--------:--------------------------:------------------------------
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
a_of_s : 001001 : : 1 -> string : Type of Array
string : 001001 : : 1 -> character : Type of Array
entry : 001001 : : undefined : Function Definition
main : 001001 : : string -> integer : Type of Function
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
many_names : 009000 : 001001 : a_of_s : Array Instance
another_name : 009000 : 001001 : string : Array Instance
one_name : 009000 : 001001 : string : Array Instance
arg : 009000 : 001001 : string : Array Instance

View File

@ -1,18 +1,26 @@
NAME : SCOPE : PARENT : TYPE : Extra annotation
-------------------------:--------:--------:--------------------------:------------------------------
entry : 001001 : : main : User Defined
main : 001001 : : primitive function type : User Defined
integer : 001001 : : Primitive : size-4 bytes
address : 001001 : : Primitive : size-8 bytes
character : 001001 : : Primitive : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive : size-1 bytes
-------------------------:--------:--------:--------------------------:------------------------------
a : 005000 : 001001 : character : User Defined
b1 : 005000 : 001001 : Boolean : User Defined
b2 : 005000 : 001001 : Boolean : User Defined
arr2 : 005000 : 001001 : address : User Defined
arr : 005000 : 001001 : address : User Defined
x : 005000 : 001001 : integer : User Defined
arg : 005000 : 001001 : string : User Defined
-------------------------:--------:--------:--------------------------:------------------------------
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
entry : 001001 : : undefined : Function Definition
rec : 001001 : : Record Type : elements-2 size-8 bytes
main : 001001 : : string -> integer : Type of Function
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
r : 006000 : 001001 : rec : Record Instance
a : 006000 : 001001 : character : Primitive Instance
b1 : 006000 : 001001 : Boolean : Primitive Instance
b2 : 006000 : 001001 : Boolean : Primitive Instance
arr2 : 006000 : 001001 : address : Primitive Instance
arr : 006000 : 001001 : address : Primitive Instance
x : 006000 : 001001 : integer : Primitive Instance
arg : 006000 : 001001 : string : Array Instance
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
y : 003000 : 001001 : integer : Primitive Instance
x : 003000 : 001001 : integer : Primitive Instance

View File

@ -1,17 +1,20 @@
NAME : SCOPE : PARENT : TYPE : Extra annotation
-------------------------:--------:--------:--------------------------:------------------------------
entry : 001001 : : main : User Defined
main : 001001 : : primitive function type : User Defined
integer : 001001 : : Primitive : size-4 bytes
address : 001001 : : Primitive : size-8 bytes
character : 001001 : : Primitive : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive : size-1 bytes
-------------------------:--------:--------:--------------------------:------------------------------
b1 : 005000 : 001001 : Boolean : User Defined
b2 : 005000 : 001001 : Boolean : User Defined
arr2 : 005000 : 001001 : address : User Defined
arr : 005000 : 001001 : address : User Defined
x : 005000 : 001001 : integer : User Defined
arg : 005000 : 001001 : string : User Defined
-------------------------:--------:--------:--------------------------:------------------------------
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
entry : 001001 : : undefined : Function Definition
main : 001001 : : string -> integer : Type of Function
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
b1 : 004000 : 001001 : Boolean : Primitive Instance
b2 : 004000 : 001001 : Boolean : Primitive Instance
arr2 : 004000 : 001001 : address : Primitive Instance
arr : 004000 : 001001 : address : Primitive Instance
x : 004000 : 001001 : integer : Primitive Instance
arg : 004000 : 001001 : string : Array Instance

View File

@ -0,0 +1,25 @@
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
bar : 001001 : : undefined : Function Definition
entry : 001001 : : undefined : Function Definition
main : 001001 : : string -> integer : Type of Function
T2 : 001001 : : rec -> integer : Type of Function
rec : 001001 : : Record Type : elements-2 size-6 bytes
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
w : 013000 : 001001 : rec : Record Instance
result : 013000 : 001001 : integer : Primitive Instance
arg : 013000 : 001001 : string : Array Instance
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
: 009000 : 001001 : : Empty Scope
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
y : 001000 : 001001 : integer : Primitive Instance
x : 001000 : 001001 : character : Primitive Instance

View File

@ -0,0 +1,19 @@
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
entry : 001001 : : undefined : Function Definition
main : 001001 : : string -> integer : Type of Function
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
bool : 015000 : 001001 : Boolean : Primitive Instance
char : 015000 : 001001 : character : Primitive Instance
add : 015000 : 001001 : address : Primitive Instance
i : 015000 : 001001 : integer : Primitive Instance
arg : 015000 : 001001 : string : Array Instance

View File

@ -0,0 +1,29 @@
NAME : SCOPE : PARENT : TYPE : EXTRA ANNOTATION :
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
tricky : 001001 : : Record Type : elements-4 size-16 bytes
rec : 001001 : : Record Type : elements-6 size-24 bytes
tom : 001001 : : Record Type : elements-2 size-8 bytes
integer : 001001 : : Primitive Type : size-4 bytes
address : 001001 : : Primitive Type : size-8 bytes
character : 001001 : : Primitive Type : size-1 bytes
string : 001001 : : 1 -> character : Type of Array
Boolean : 001001 : : Primitive Type : size-4 bytes
reserve type : 001001 : : integer -> address : Type of Function
reserve : 001001 : : undefined : Function Definition
release type : 001001 : : address -> integer : Type of Function
release : 001001 : : undefined : Function Definition
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
k2 : 003000 : 001001 : integer : Primitive Instance
b2 : 003000 : 001001 : Boolean : Primitive Instance
k1 : 003000 : 001001 : integer : Primitive Instance
b1 : 003000 : 001001 : Boolean : Primitive Instance
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
y : 002000 : 001001 : integer : Primitive Instance
b : 002000 : 001001 : Boolean : Primitive Instance
d : 002000 : 001001 : character : Primitive Instance
c : 002000 : 001001 : character : Primitive Instance
prev : 002000 : 001001 : tom : Record Instance
x : 002000 : 001001 : integer : Primitive Instance
------------------------------:--------:--------:-----------------------------------:-----------------------------------:
y : 001000 : 001001 : integer : Primitive Instance
x : 001000 : 001001 : integer : Primitive Instance