https://github.com/adimit/sicp
Following SICP along with an implementation in Rust
https://github.com/adimit/sicp
Last synced: 7 months ago
JSON representation
Following SICP along with an implementation in Rust
- Host: GitHub
- URL: https://github.com/adimit/sicp
- Owner: adimit
- Created: 2020-08-03T20:20:23.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-09-26T19:19:30.000Z (over 5 years ago)
- Last Synced: 2025-02-15T16:42:32.368Z (over 1 year ago)
- Language: Rust
- Size: 39.1 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.org
Awesome Lists containing this project
README
* Scheme in Rust
This is an experimental Scheme in Rust. It serves as an accompaniment to reading SICP, and has no purpose outside of that.
* Tasks
** DONE =EvaluationResult= needs spans
Error reporting could be improved by adding spans to =EvaluationResult=
** DONE Test for error messages reporting locations
Any error about evaluation or parsing should always carry positional information. Refactor ReplError to carry a span and implement =fmt::Display=
** DONE Refactor
** DONE (+12) should not give invalid function head expression Int(12)
=+12= should be parsed as a symbol. It's also weird that =+12= doesn't just work now, because shouldn't it be a =Sym(+)= followed by =Int(12)=?
CAVEAT: our behaviour mirrors that of Scheme's reference interpreter exactly, so I don't know that it's a bug at all.
Ignore this for now.
** TODO Add other basic arithmetic operations
subtraction, division multiplication
** TODO Add floating point numbers
floating point numbers "pollute" i.e. if there's one floating point number anywhere in the expression, the result is fp, otherwise int.
** TODO Evaluate =thiserr= and =eyre=
Created: [2020-08-26 Wed 17:58]
Ref: main.org [[file:~/org/main.org::*RustConf talks][RustConf talks]]