You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
defSymEngine.formula &blockblock.parameters.empty?andfail(ArgumentError,"Block should list all expected symbols")block.parameters.map(&:first).uniq == [:opt]orfail(ArgumentError,"Only plain parameters are supported (no defaults, no *rest, no keyword args)")symbols=block.parameters.map(&:last).map(&SymEngine::Symbol.method(:new))block.call(*symbols)end
There's almost no "dangerous" magics (with method_missing, instance_eval and stuff), and seems pretty useful?..
The text was updated successfully, but these errors were encountered:
OK, it is not the time for it currently, just an idea for future.
Usage:
Naive implementation:
There's almost no "dangerous" magics (with
method_missing
,instance_eval
and stuff), and seems pretty useful?..The text was updated successfully, but these errors were encountered: