Class: RParsec::Failures
- Inherits:
-
Object
- Object
- RParsec::Failures
- Defined in:
- lib/rparsec/parsers.rb
Class Method Summary collapse
Class Method Details
.add_error(err, e) ⇒ Object
27 28 29 30 31 32 33 34 35 |
# File 'lib/rparsec/parsers.rb', line 27 def self.add_error(err, e) return e if err.nil? return err if e.nil? cmp = compare_error(err, e) return err if cmp > 0 return e if cmp < 0 err # merge_error(err, e) end |