Skip to content

Releases: mrLSD/semantic-analyzer-rs

v0.4.1

26 Mar 17:50
76126a5
Compare
Choose a tag to compare

➡️ Generic Expression value: custom Expression value with custom instruction as result for Semantic Stack Context. Extended generalized solution for Semantic Stack Context instructions including codec feature for serialization extended expressions.
➡️ Extended tests for Generic Expression value: custom Expression instructions.

  • #30 - Feat: refactore extend expression - @mrLSD .

v0.4.0

16 Jan 16:00
fb7afaa
Compare
Choose a tag to compare

Introduced a new awesome possibility - extensibility 🔋.

➡️ Generic Expression value: custom Expression value with custom instruction as result for Semantic Stack Context. It's bring possibility to extend AST for the custom needs of compilers and extends additional generic custom instructions for the next step of code generation.

➡️ Refactored tests structure

  • #27 [Feature] Add extensibility to Expression Value
  • #26 Feat: refactor tests structure organization - @mrLSD
  • #25 Feat: Extend ExpressionValue with a custom generic extensible field - @mrLSD

v0.3.3

12 Dec 16:55
2e702b1
Compare
Choose a tag to compare

➡️ Added Serde serializer, which can be enabled via the codec feature flag.
➡️ Extended README.
➡️ Extended tests.

💠 It's most useful for:

  • AST - AST can be presented with (se/dese)rialization.
  • State - whole state as serialization result
  • SematicStack - serialized instructions set

Contribution

  • #23 Feat: add Serde as codec feature - @mrLSD
  • #21 [Feature]: Implement Serde serializer

v0.3.2

02 Dec 23:33
177e077
Compare
Choose a tag to compare

🍰 Added function parameters as variables to BlockState with 🌷 additional instruction FunctionArg to SemanticStack for allocation 🎇 and bind explicitly in Codegen backend.

💡 Tests

Extended tests, that covers new instructions and func-params additions.

🍏 Clippy

Increased clippy level to most maximum and fixed all clippy-related issues 🍾.

  • #20 - Feat: Function parameters init as variables @mrLSD
  • #18 - Feature: Function parameters init as variables

v0.3.1

24 Nov 10:02
v0.3.1
eea35c6
Compare
Choose a tag to compare

Introduced extended 🌴 BlockState context:

🔦 To simplify the fetching process for Codegen backends, there is added the changes:

  • for the parent BlockState "flatten" all children's contexts. It means parent context will also include children's contexts. And it has linear representations. At the same time, it has children BlockState with their own context
  • root BlockState contains flattened linear context related to all children's BlockState context.

🔦 Tests

  • Added additional tests for all related flattened BoclState contexts.
  • Added tests for BlockState parent invokation.

🏦 BlockState changes

🔦 Added traits:

  • SemanticContext
  • GlobalSemanticContext

For BlockState trait SemanticContext implementation added invokcation for all parent BlockState nodes in context. It's guaranteed, that all parent context nodes have the same leaves as children. And root contains full representation of children's instructions.

  • #19 - Feat: flatten tree BlockState for SemanticStackContext - @mrLSD
  • #16 - Feature: flatten root BlockState for SemanticStackContext

v0.3.0

18 Nov 16:45
ef93e56
Compare
Choose a tag to compare

The release contains several improvements and breaking changes. Extended documentations and tests. Added reference to example usage with mrLSD/toy-codegen project.

🥇 Registers

Implemented register numbers for expressions and assignment operations.

The main point is to track correct expressions, values, and function parameters.

🥈 Toy Codegen

As an example of usage for semantic-alalyzer-rs is implemented as a separate project toy-codegen. It shows how to use SemanticStack for Codegen generation. Added to README.md.

📝 Documentation

  • Extended README docs
  • Extended code documentation for SemanticStack functions generator.

Contribution

  • #17 Feat: extend SemanticStack with registers (@mrLSD)
  • #13 Add registers number to SemanticStackContext definitions

v0.2.6

11 Nov 10:41
5ad44c2
Compare
Choose a tag to compare

After termination instructions return, break, and continue, if other instructions presented added errors to state.

This applies to statements

  • function-body
  • if-body
  • else-if-body
  • if-loop-body
  • else-if-loop-body
  • loop-body

Loops

🏁 Checked if the return instruction was present, then removed extra jump-to: loop-end, and set-label: loop-end. And added the tests.

  • #15 - Feat: after termination instructions return, break, continue do not allow other instructions (@mrLSD)
  • #10 - Feature: after termination instructions return, break, continue do not allow other instructions (@mrLSD)

v0.2.5

08 Nov 09:15
7e8883a
Compare
Choose a tag to compare

Refactored if-end jump logic for if-condition state.

If-body block state

For the if-body block state, when called return anyway after this the JumpTo if-end instruction is called. It's redundant, refactored, and added an additional check for label instruction JumpTo is manual-return for the current block state. If manual-return is set JumpTo context instruction is removed.

  • #9 - Improve return logic for function-body and if-body state (@mrLSD)
  • #14 Feat: refactor if-end jump logic (@mrLSD)

v0.2.4

05 Nov 20:59
b25203d
Compare
Choose a tag to compare

Fixed issues with SemanticStackContext :atom: generation, improved semantic analyzer, covered with 💯% tests coverage.

Fixes

  • Fixed issue #8 with multiple returns for the function-body semantic analysis.
  • Fixed If-loop label parameters fail when missing label parameters for the loop.
  • Fixed issue #11 and only one if-end label exists for the if-condition.
  • Fixed issue #12 for loop-body repeatition and extended tests for that.

Tests

Extended semantic analyzer tests:

  • if-conditions
  • loops
  • function-body
  • main-run
  • covered with tests all SemanticStackContext instructions

Coverage

💯 100% tests coverage

  • #7 Feat: fix multiple return issues and extend analyzer tests @mrLSD
  • #8 For semantic function body state return can call multiple times
  • #11 Fix if-end label instruction for IfStatement: if-else, else-if statements
  • #12 Fix loop-begin label for the loop-statement

v0.2.3

20 Oct 21:24
2992080
Compare
Choose a tag to compare

Added tests and increased tests coverage ⬆️. Significantly improved Github CI 🤖.

  • ☑️ Extended tests for function-declaration
  • ☑️ Extended tests for function-call
  • ☑️ Extended tests for let-binding
  • ☑️ Extended tests for binding
  • ☑️ Extended CI

- #6 - Extend tests and CI for let-binding, function-declarations, bindings. Extend CI (@mrLSD)