Class: CBOR_DIAG::App_h
- Inherits:
-
Object
- Object
- CBOR_DIAG::App_h
- Defined in:
- lib/cbor-diagnostic-app/h.rb
Class Method Summary collapse
Class Method Details
.decode(_, s) ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'lib/cbor-diagnostic-app/h.rb', line 4 def self.decode(_, s) parser = HGRAMMARParser.new ast = parser.parse(s) if !ast raise ArgumentError, "cbor-diagnostic: Parse Error in h'#{s}':\n" << EDN.reason(parser, s) end ast.ast end |