Tristan B. Velloza Kildaire deavmi
  • Stellenbosch, South Africa
  • https://deavmi.assigned.network
  • I ❤️ programming and computers. I have a big interest in compiler and interpreter design and implementation and also an interest in networking and fmts/protos.

  • Joined on 2021-12-21
deavmi commented on issue tlang/tlang#7 2022-12-17 17:06:33 +00:00
Function return statement

Return statements are now implemented

deavmi commented on issue tlang/tlang#7 2022-12-17 17:05:50 +00:00
Function return statement

Tests run and corerct values arise from the return statement in simple_functions.t on commit d1b3319a74efc4ed37c6b492a5d374f93e3f3e74 on vardec_varass_dependency branch.

deavmi opened issue tlang/tlang#62 2022-12-17 16:54:29 +00:00
Add error handling to CodeEmitter
deavmi commented on issue tlang/tlang#44 2022-12-17 16:53:28 +00:00
CodeEmitter

Still waiting on adding error handling to the queue manegement functions

deavmi commented on issue tlang/tlang#44 2022-12-17 16:53:11 +00:00
CodeEmitter

Issue #43 is done

deavmi commented on issue tlang/tlang#42 2022-12-17 15:45:56 +00:00
Function definitions

Function return support is almost done, awaiitng a merge #7

deavmi commented on issue tlang/tlang#7 2022-12-17 15:42:22 +00:00
Function return statement

All that is left is semantic analysis, which shouldn't be too hard

deavmi commented on issue tlang/tlang#7 2022-12-17 15:40:52 +00:00
Function return statement

Type checking is oustanding But will be handled from #61

deavmi opened issue tlang/tlang#61 2022-12-17 15:38:27 +00:00
Type checking
deavmi commented on issue tlang/tlang#7 2022-12-17 15:37:28 +00:00
Function return statement

Typechecking is outstanding

deavmi opened issue tlang/tlang#60 2022-12-17 15:35:04 +00:00
Lexer stuff
deavmi commented on issue tlang/tlang#7 2022-12-17 15:19:37 +00:00
Function return statement

TypeChecker (and CodeGen)

No typechecking yet, but we do the following in order to pop the expression Value instruction that was on the stack codeQueue (scratchpad) and then we embed it…

deavmi commented on issue tlang/tlang#59 2022-12-17 15:11:45 +00:00
Enforce return statements to only be allowed at end of function body

Solution

We could do this in the parser but that doesn't feel right, or well it can but the dependency generation is where we make sense of the parse tree generated by the parser (and…

deavmi opened issue tlang/tlang#59 2022-12-17 15:09:57 +00:00
Enforce return statements to only be allowed at end of function body
deavmi commented on issue tlang/tlang#7 2022-12-17 15:06:26 +00:00
Function return statement

Data (Parser nodes)

We have added a parser node ReturnStmt (this has been here for some time but we needed to actually weight it with a weight above the default of 0 - which actually…

deavmi commented on issue tlang/tlang#7 2022-12-17 15:02:42 +00:00
Function return statement

Dependency

We have the following added to generalPass(COntainer, COntext) now:

/**
* Return statement
*/
else if(cast(ReturnStmt)entity)
{
	ReturnStmt returnStatement =
deavmi commented on issue tlang/tlang#7 2022-12-17 15:00:49 +00:00
Function return statement

Emmiting

I have now done the following:

  • Created a ReturnInstruction which embeds the epxresiosn instruction, so it can be pulled out by the emitter later and we can do the following:
deavmi commented on issue tlang/tlang#7 2022-12-17 14:59:58 +00:00
Function return statement

Function return statements being worked on now

deavmi commented on issue tlang/tlang#42 2022-12-17 14:58:57 +00:00
Function definitions

Parser support done

deavmi commented on issue tlang/tlang#42 2022-12-17 14:58:21 +00:00
Function definitions

Issue #52 closed