Sha256: 3c9996dd64c28bed0d8eb812018763378d682322b2641d3c93522d5606657f42
Contents?: true
Size: 411 Bytes
Versions: 2
Compression:
Stored size: 411 Bytes
Contents
module Finitio module Syntax module NamedConstraint def compile(var_name) { constraint_name.to_sym => expression.compile(var_name) } end def to_ast(var_name) [ :constraint, constraint_name.to_s, [:fn, [:parameters, var_name], [:source, expression.to_s.strip]] ] end end # module NamedConstraint end # module Syntax end # module Finitio
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
finitio-0.4.1 | lib/finitio/syntax/named_constraint.rb |
finitio-0.4.0 | lib/finitio/syntax/named_constraint.rb |