You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently XD Pascal generates machine instructions 'on-the-fly', like almost all early Pascal compilers, including Turbo Pascal. But building an AST can help perform larger-scale optimizations than those (peephole) optimizations available now.
Moreover, using an AST will eliminate the need for the clumsy MakeCStack procedure designed to deal with stdcall and cdecl functions.
Last but not least, it would probably help correctly compile expressions like a.f(x)^.b. Now it's a syntax error because the parser does not know when parsing f(x) whether its result is dereferenced (and so becomes a 'designator') or not (and so becomes a 'factor').
The text was updated successfully, but these errors were encountered:
Currently XD Pascal generates machine instructions 'on-the-fly', like almost all early Pascal compilers, including Turbo Pascal. But building an AST can help perform larger-scale optimizations than those (peephole) optimizations available now.
Moreover, using an AST will eliminate the need for the clumsy
MakeCStack
procedure designed to deal withstdcall
andcdecl
functions.Last but not least, it would probably help correctly compile expressions like
a.f(x)^.b
. Now it's a syntax error because the parser does not know when parsingf(x)
whether its result is dereferenced (and so becomes a 'designator') or not (and so becomes a 'factor').The text was updated successfully, but these errors were encountered: