Skip to content

Commit

Permalink
Skema Docs CAST Development Notes (#736)
Browse files Browse the repository at this point in the history
## Summary of Changes
This PR makes a small modification to the development notes that live in
the skema docs website.
It adds a new small section detailing notes on how to use Var and Name
constructs.
More things related to CAST development will be added to this section
when the need arises.

Resolves #733
  • Loading branch information
titomeister authored Dec 22, 2023
1 parent 398bfdf commit 3e38c48
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
9 changes: 9 additions & 0 deletions docs/dev/cast_frontend.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
## CAST FrontEnd Generation Notes
### Using Var vs Name nodes
Currently in the CAST generation we have a convention on when to use Var and Name nodes.
The GroMEt generation depends on these being conistent, otherwise there will be errors in the generation.
In the future this convention might change, or be eliminated altogether, but for now this is the current set of rules.

- If the variable in question is being stored into (i.e. as the result of an assignment), then we use Var. Even if it's a variable that has already been defined.
- If the variable in question is being read from (i.e. being used in an expression), then we use Name.
- Whenever we're creating a function call Call() node, the name of the function is specified using the Name node.
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ nav:
- Generating code2fn model coverage reports: "dev/generating_code2fn_model_coverage.md"
- Using code ingestion frontends: "dev/using_code_ingestion_frontends.md"
- Using tree-sitter preprocessor: "dev/using_tree_sitter_preprocessor.md"
- CAST Front-end generation: "dev/cast_frontend.md"
- Coverage:
- Code2fn coverage reports: "coverage/code2fn_coverage/report.html"
- TA1 Integration Dashboard: "https://integration-dashboard.terarium.ai/TA1"
Expand Down

0 comments on commit 3e38c48

Please sign in to comment.