Skip to content

Add Parse<->Print isomorphism tests #48

Open
@GuiltyDolphin

Description

@dorchard As discussed, this is a suggestion to add tests to help ensure consistency of the parser/printer.

Gen->Print->Parse

We could use QuickCheck to generate syntax trees, then 'pretty' show them in a canonical way and parse them. We would expect the parsed syntax trees to be the same (modulo some information such as position) as the original syntax tree.

File->Parse->Print

Assuming we had example programs in a 'pretty' canonical form, we would expect parsing the files, then printing them, to give the same text as the original file.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions