Files
modeling-app/rust
Adam Chalmers cc07400719 KCL: Fix 'cryptic' error when referencing a variable in its own declaration
Previously, `x = cos(x)` would just say "`x` is undefined". Now it says
that `x` cannot be referenced in its own definition, try using a different
variable instead.

To do this, I've added a new `Option<String>` field to the mod-local
executor context, tracking the current variable declaration. This means
cloning some strings, implying a small performance hit. I think it's fine,
for the better diagnostics.

In the future we could refactor this to use a &str
or store variable labels in stack-allocated strings like docs.rs/compact_str
or something.

Closes https://github.com/KittyCAD/modeling-app/issues/6072#issuecomment-2923227477
2025-05-30 17:00:22 -05:00
..
2025-03-13 23:38:41 -07:00
2025-05-30 13:48:17 -04:00
2025-05-30 13:48:17 -04:00
2025-05-30 13:48:17 -04:00
2025-05-30 13:48:17 -04:00
2025-05-30 13:48:17 -04:00
2025-05-30 13:48:17 -04:00
2025-03-04 22:21:12 -08:00

Rust Crates

Releasing

  1. Make sure your working directory is this directory.
  2. Bump the versions of the crates:
    just bump-kcl-crate-versions 
    
  3. Commit the changes:
    git add .
    git commit -m "Bump versions"
    
  4. Push the changes and get your PR approved.
  5. Publish the crates:
    just publish-kcl {version}
    
    • This will publish the relevant crates and push a new tag with the prefix kcl-. DO NOT SET THE PREFIX TO kcl- when you run the command. The just command will do that for you.
    • The tag will then trigger the release of kcl-python-bindings and kcl-language-server.