Skip to content

Single quote bug in parse-result #69

@ruricolist

Description

@ruricolist

When using parse-result, the symbol quote does not appear as a child of the expression when using the single-quote reader macro.

Minimal example:

(defclass trivial-parse-result (eclector.parse-result:parse-result-client) ())

(defmethod eclector.parse-result:make-expression-result
    ((client trivial-parse-result) result children source)
  (list :result result :children children))

If you write out quote you get one result:

(eclector.parse-result:read-from-string (make-instance 'trivial-parse-result)
                                        "(quote nil)")
=> ((:RESULT 'NIL :CHILDREN
    ((:RESULT QUOTE :CHILDREN NIL) (:RESULT NIL :CHILDREN NIL))))

But if you use a single quote you get a different result:

(eclector.parse-result:read-from-string (make-instance 'trivial-parse-result)
                                        "'nil")
=> (:RESULT 'NIL :CHILDREN ((:RESULT NIL :CHILDREN NIL)))

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationSomething should be documented

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions