Closed rmolinari closed 1 month ago
Thank you. Yes ... I imagine that is a not so uncommon bug in our current codebase. Currently, the design is such, as we don't want functions to hold another value (it's name) at runtime in hope to be as lightweight as possible (because everything is function in Rye, also all that are usually language specific constructs (if/for/fn/..). We will start profiling current implementation at some point and if it shows that this is not needed it will be changed to form that will be easier to be consistent. Or we would make a tool that checks this.
We will see ... for now, there is only a manual method so PR with these fixes is more than welcome!
I'll create a PR.
~Separately: how can I run the tests locally, to make sure I didn't break anything?~
I found the instructions in the README
Testing script will get improved. Currently you can run it with:
cd tests
rye . test
rye . doc # creates the html docs out of tests
Some function names of the form
foo\bar
appear asfoo-bar
in their own error messages.For example:
Note that the function is called "split-every" in the error message instead of "split\every". There are some other such cases in
evaldo/builtins.go
.I have a fix for at least some of these in my fork and am happy to create a pull request. This issue is, in part, to satisfy the request in CONTRIBUTIONS.md to create an issue before the PR.
Q: how do I run all the tests to make sure I haven't broken anything?