Module: Trepan::Condition
- Defined in:
- app/condition.rb
Class Method Summary collapse
Class Method Details
.valid_condition?(str) ⇒ Boolean
4 5 6 7 8 9 10 11 12 |
# File 'app/condition.rb', line 4 def valid_condition?(str) begin RubyVM::InstructionSequence.compile(str) rescue SyntaxError => e return nil rescue nil end end |