To reproduce
Just run something like this in the repl
(map eval-string '("(+ 1 2 3)"))
Outputs
Unable to locate source and span information for this error: Error: TypeMismatch: map expected a function
eval also gives the same error.
However, eval! works
I'm using the latest master which is e387a1f at the time of writing.
For context, I'm trying to implement string interpolation, i.e. (interpolate "this is an interpolated string ${(+ 1 2 3)})". I also tried calling Engine::run from within a rust function, which resulted in some strange errors (if interested, IllustratedMan-code/piphany@0636082) is the commit where I tried to implement interpolation from rust. It almost worked, except the strings can't get the context of the outside expressions. You can see the error by doing a cargo run. Any tips on how I should go about this would be greatly appreciated!
To reproduce
Just run something like this in the repl
Outputs
evalalso gives the same error.However,
eval!worksI'm using the latest master which is e387a1f at the time of writing.
For context, I'm trying to implement string interpolation, i.e.
(interpolate "this is an interpolated string ${(+ 1 2 3)})". I also tried callingEngine::runfrom within a rust function, which resulted in some strange errors (if interested, IllustratedMan-code/piphany@0636082) is the commit where I tried to implement interpolation from rust. It almost worked, except the strings can't get the context of the outside expressions. You can see the error by doing acargo run. Any tips on how I should go about this would be greatly appreciated!