├── .github └── workflows │ └── test.yml ├── .gitignore ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── Retrie.hs ├── Retrie ├── AlphaEnv.hs ├── CPP.hs ├── Context.hs ├── Debug.hs ├── Elaborate.hs ├── ExactPrint.hs ├── ExactPrint │ └── Annotated.hs ├── Expr.hs ├── Fixity.hs ├── FreeVars.hs ├── GHC.hs ├── GroundTerms.hs ├── Monad.hs ├── Options.hs ├── PatternMap │ ├── Bag.hs │ ├── Class.hs │ └── Instances.hs ├── Pretty.hs ├── Quantifiers.hs ├── Query.hs ├── Replace.hs ├── Rewrites.hs ├── Rewrites │ ├── Function.hs │ ├── Patterns.hs │ ├── Rules.hs │ └── Types.hs ├── Run.hs ├── SYB.hs ├── Subst.hs ├── Substitution.hs ├── Types.hs ├── Universe.hs └── Util.hs ├── Setup.hs ├── bin └── Main.hs ├── demo └── Main.hs ├── hse └── Fixity.hs ├── retrie.cabal └── tests ├── AllTests.hs ├── Annotated.hs ├── CPP.hs ├── Demo.hs ├── Dependent.hs ├── Exclude.hs ├── Golden.hs ├── GroundTerms.hs ├── Ignore.hs ├── Main.hs ├── ParseQualified.hs ├── Targets.hs ├── Util.hs └── inputs ├── Adhoc.test ├── Adhoc2.custom ├── Backticks.test ├── Backticks2.test ├── CPP.test ├── CPPConflict.test ├── Capture.test ├── Combined.test ├── Commas.test ├── Comments.test ├── DependentStmt.custom ├── Foo.test ├── FooFold.test ├── Imports.test ├── Iterate.test ├── MatchGroup.test ├── Operator.test ├── Parens.test ├── PartialF.test ├── PartialU.test ├── PatBind.test ├── PatternSyn1.test ├── PatternSyn2.test ├── Qualified.test ├── Query.custom ├── Readme.custom ├── Readme1.test ├── Readme2.test ├── Readme3.test ├── Readme4.test ├── Readme5.test ├── Records.test ├── Records2.test ├── Recursion.test ├── Shadowing.test ├── Types.test ├── Types2.test ├── Types3.test ├── Types4.test └── Union.test /.github/workflows/test.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/.github/workflows/test.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /dist-newstyle/ 2 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/CHANGELOG.md -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/CODE_OF_CONDUCT.md -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/CONTRIBUTING.md -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/README.md -------------------------------------------------------------------------------- /Retrie.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie.hs -------------------------------------------------------------------------------- /Retrie/AlphaEnv.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/AlphaEnv.hs -------------------------------------------------------------------------------- /Retrie/CPP.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/CPP.hs -------------------------------------------------------------------------------- /Retrie/Context.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Context.hs -------------------------------------------------------------------------------- /Retrie/Debug.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Debug.hs -------------------------------------------------------------------------------- /Retrie/Elaborate.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Elaborate.hs -------------------------------------------------------------------------------- /Retrie/ExactPrint.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/ExactPrint.hs -------------------------------------------------------------------------------- /Retrie/ExactPrint/Annotated.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/ExactPrint/Annotated.hs -------------------------------------------------------------------------------- /Retrie/Expr.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Expr.hs -------------------------------------------------------------------------------- /Retrie/Fixity.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Fixity.hs -------------------------------------------------------------------------------- /Retrie/FreeVars.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/FreeVars.hs -------------------------------------------------------------------------------- /Retrie/GHC.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/GHC.hs -------------------------------------------------------------------------------- /Retrie/GroundTerms.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/GroundTerms.hs -------------------------------------------------------------------------------- /Retrie/Monad.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Monad.hs -------------------------------------------------------------------------------- /Retrie/Options.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Options.hs -------------------------------------------------------------------------------- /Retrie/PatternMap/Bag.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/PatternMap/Bag.hs -------------------------------------------------------------------------------- /Retrie/PatternMap/Class.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/PatternMap/Class.hs -------------------------------------------------------------------------------- /Retrie/PatternMap/Instances.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/PatternMap/Instances.hs -------------------------------------------------------------------------------- /Retrie/Pretty.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Pretty.hs -------------------------------------------------------------------------------- /Retrie/Quantifiers.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Quantifiers.hs -------------------------------------------------------------------------------- /Retrie/Query.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Query.hs -------------------------------------------------------------------------------- /Retrie/Replace.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Replace.hs -------------------------------------------------------------------------------- /Retrie/Rewrites.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Rewrites.hs -------------------------------------------------------------------------------- /Retrie/Rewrites/Function.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Rewrites/Function.hs -------------------------------------------------------------------------------- /Retrie/Rewrites/Patterns.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Rewrites/Patterns.hs -------------------------------------------------------------------------------- /Retrie/Rewrites/Rules.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Rewrites/Rules.hs -------------------------------------------------------------------------------- /Retrie/Rewrites/Types.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Rewrites/Types.hs -------------------------------------------------------------------------------- /Retrie/Run.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Run.hs -------------------------------------------------------------------------------- /Retrie/SYB.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/SYB.hs -------------------------------------------------------------------------------- /Retrie/Subst.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Subst.hs -------------------------------------------------------------------------------- /Retrie/Substitution.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Substitution.hs -------------------------------------------------------------------------------- /Retrie/Types.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Types.hs -------------------------------------------------------------------------------- /Retrie/Universe.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Universe.hs -------------------------------------------------------------------------------- /Retrie/Util.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Retrie/Util.hs -------------------------------------------------------------------------------- /Setup.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/Setup.hs -------------------------------------------------------------------------------- /bin/Main.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/bin/Main.hs -------------------------------------------------------------------------------- /demo/Main.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/demo/Main.hs -------------------------------------------------------------------------------- /hse/Fixity.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/hse/Fixity.hs -------------------------------------------------------------------------------- /retrie.cabal: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/retrie.cabal -------------------------------------------------------------------------------- /tests/AllTests.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/AllTests.hs -------------------------------------------------------------------------------- /tests/Annotated.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Annotated.hs -------------------------------------------------------------------------------- /tests/CPP.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/CPP.hs -------------------------------------------------------------------------------- /tests/Demo.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Demo.hs -------------------------------------------------------------------------------- /tests/Dependent.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Dependent.hs -------------------------------------------------------------------------------- /tests/Exclude.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Exclude.hs -------------------------------------------------------------------------------- /tests/Golden.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Golden.hs -------------------------------------------------------------------------------- /tests/GroundTerms.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/GroundTerms.hs -------------------------------------------------------------------------------- /tests/Ignore.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Ignore.hs -------------------------------------------------------------------------------- /tests/Main.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Main.hs -------------------------------------------------------------------------------- /tests/ParseQualified.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/ParseQualified.hs -------------------------------------------------------------------------------- /tests/Targets.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Targets.hs -------------------------------------------------------------------------------- /tests/Util.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/Util.hs -------------------------------------------------------------------------------- /tests/inputs/Adhoc.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Adhoc.test -------------------------------------------------------------------------------- /tests/inputs/Adhoc2.custom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Adhoc2.custom -------------------------------------------------------------------------------- /tests/inputs/Backticks.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Backticks.test -------------------------------------------------------------------------------- /tests/inputs/Backticks2.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Backticks2.test -------------------------------------------------------------------------------- /tests/inputs/CPP.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/CPP.test -------------------------------------------------------------------------------- /tests/inputs/CPPConflict.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/CPPConflict.test -------------------------------------------------------------------------------- /tests/inputs/Capture.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Capture.test -------------------------------------------------------------------------------- /tests/inputs/Combined.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Combined.test -------------------------------------------------------------------------------- /tests/inputs/Commas.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Commas.test -------------------------------------------------------------------------------- /tests/inputs/Comments.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Comments.test -------------------------------------------------------------------------------- /tests/inputs/DependentStmt.custom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/DependentStmt.custom -------------------------------------------------------------------------------- /tests/inputs/Foo.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Foo.test -------------------------------------------------------------------------------- /tests/inputs/FooFold.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/FooFold.test -------------------------------------------------------------------------------- /tests/inputs/Imports.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Imports.test -------------------------------------------------------------------------------- /tests/inputs/Iterate.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Iterate.test -------------------------------------------------------------------------------- /tests/inputs/MatchGroup.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/MatchGroup.test -------------------------------------------------------------------------------- /tests/inputs/Operator.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Operator.test -------------------------------------------------------------------------------- /tests/inputs/Parens.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Parens.test -------------------------------------------------------------------------------- /tests/inputs/PartialF.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/PartialF.test -------------------------------------------------------------------------------- /tests/inputs/PartialU.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/PartialU.test -------------------------------------------------------------------------------- /tests/inputs/PatBind.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/PatBind.test -------------------------------------------------------------------------------- /tests/inputs/PatternSyn1.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/PatternSyn1.test -------------------------------------------------------------------------------- /tests/inputs/PatternSyn2.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/PatternSyn2.test -------------------------------------------------------------------------------- /tests/inputs/Qualified.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Qualified.test -------------------------------------------------------------------------------- /tests/inputs/Query.custom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Query.custom -------------------------------------------------------------------------------- /tests/inputs/Readme.custom: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Readme.custom -------------------------------------------------------------------------------- /tests/inputs/Readme1.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Readme1.test -------------------------------------------------------------------------------- /tests/inputs/Readme2.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Readme2.test -------------------------------------------------------------------------------- /tests/inputs/Readme3.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Readme3.test -------------------------------------------------------------------------------- /tests/inputs/Readme4.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Readme4.test -------------------------------------------------------------------------------- /tests/inputs/Readme5.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Readme5.test -------------------------------------------------------------------------------- /tests/inputs/Records.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Records.test -------------------------------------------------------------------------------- /tests/inputs/Records2.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Records2.test -------------------------------------------------------------------------------- /tests/inputs/Recursion.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Recursion.test -------------------------------------------------------------------------------- /tests/inputs/Shadowing.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Shadowing.test -------------------------------------------------------------------------------- /tests/inputs/Types.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Types.test -------------------------------------------------------------------------------- /tests/inputs/Types2.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Types2.test -------------------------------------------------------------------------------- /tests/inputs/Types3.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Types3.test -------------------------------------------------------------------------------- /tests/inputs/Types4.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Types4.test -------------------------------------------------------------------------------- /tests/inputs/Union.test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/facebookincubator/retrie/HEAD/tests/inputs/Union.test --------------------------------------------------------------------------------