I have a vector2 type:
type vec2
x as float
y as float
endtype
and these three functions:
function createVector2(x as float, y as float)
ret as vec2
ret.x=x
ret.y=y
endfunction ret
function multiply(x as vec2)
x.x=x.x*5
x.y=x.y*5
endfunction x
function printVector2(x as vec2)
asdf$="("+Str(x.x)+","+Str(x.y)+")"
print(asdf$)
endfunction
When I call the functions like so:
v as vec2
v=createVector2(2,4)
v=multiply(v)
printVector2(v)
It compiles and runs fine, and displays the correct results.
However, when I nest the commands like so:
printVector2(multiply(createVector2(2,4)))
The compiler runs for a bit, and then terminates with the error:
Quote: "Compiling: main.agc
Process terminated with status -1073741819 (0 minutes, 3 seconds)"
I'm not sure if this is a compiler error or a syntax issue, so I thought I'd ask here before sending a bug report.