narrowtux / abacus

Parses and evaluates mathematical expressions in Elixir. Inspired by math.js
MIT License
84 stars 18 forks source link

Possible to concatenate strings? #29

Open rgraff opened 6 days ago

rgraff commented 6 days ago

I was hoping that this would automagically work?

Abacus.eval("concat(a,b)", %{"a" => "hello ", "b" => "world"})
error: undefined variable "var0"

Abacus.eval("a + \" \" + b", %{"a" => "hello", "b" => "world"})
{:error, %ArithmeticError{message: "bad argument in arithmetic expression"}}

I don't see any string functions in the source code.