├── .gitattributes ├── .gitignore ├── .stylish-haskell.yaml ├── .travis.yml ├── Crux ├── AST.hs ├── Error.hs ├── Gen.hs ├── HashTable.hs ├── IORef.hs ├── JSBackend.hs ├── JSTree.hs ├── Lex.hs ├── Main.hs ├── Module.hs ├── Module │ └── Types.hs ├── ModuleName.hs ├── Parse.hs ├── Pos.hs ├── Prelude.hs ├── Project.hs ├── SymbolTable.hs ├── Text.hs ├── Tokens.hs ├── TrackIO.hs ├── TypeVar.hs ├── Typecheck.hs ├── Typecheck │ ├── Env.hs │ ├── Inst.hs │ ├── Monad.hs │ ├── Occurs.hs │ ├── Quantify.hs │ ├── TypeAlloc.hs │ ├── Types.hs │ └── Unify.hs └── Util.hs ├── LICENSE.txt ├── README.md ├── Setup.hs ├── closure-service ├── .gitignore ├── .mvn │ └── wrapper │ │ ├── maven-wrapper.jar │ │ └── maven-wrapper.properties ├── LICENSE ├── Procfile ├── Procfile.windows ├── README.md ├── app.json ├── mvnw ├── mvnw.cmd ├── pom.xml ├── src │ └── main │ │ └── java │ │ └── Main.java └── system.properties ├── crux.cabal ├── crux.yaml ├── cruxjs ├── .gitignore ├── LICENSE ├── README.md ├── Setup.hs ├── crux.yaml ├── cruxjs.cabal ├── jsbits │ ├── wrap.intro.js │ └── wrap.outro.js ├── npm │ ├── .gitignore │ └── cruxlang │ │ ├── cli.js │ │ └── package.json ├── s │ ├── build │ ├── sass-watcher │ └── server ├── src │ ├── Main.hs │ ├── compiler-worker.cx │ ├── crux.cx │ └── playground.cx ├── stack.yaml └── stage │ ├── index.html │ └── style.scss ├── cxconfig.yaml ├── doc ├── design │ ├── angle-brackets.md │ ├── arrays.md │ ├── case.md │ ├── cli.md │ ├── exceptions.md │ ├── ffi.md │ ├── for-loops.md │ ├── hypotheses.md │ ├── language-references.md │ ├── layout.md │ ├── letrec.md │ ├── methods.md │ ├── modules.md │ ├── mutability.md │ ├── names.md │ ├── namespaces.md │ ├── npm-integration.md │ ├── objects.md │ ├── option.md │ ├── positioning.md │ ├── precedence.md │ ├── record-traits.md │ ├── records-with-optional-fields.md │ ├── records.md │ ├── row-polymorphism-unification.md │ ├── strings.md │ ├── style.md │ ├── sugar.md │ ├── traits.md │ └── unification-table.md └── tutorial │ └── writing-npm-module.md ├── editor-support ├── atom │ └── language-crux │ │ ├── .gitignore │ │ ├── CHANGELOG.md │ │ ├── LICENSE.md │ │ ├── README.md │ │ ├── grammars │ │ └── crux.cson │ │ ├── keymaps │ │ └── language-crux.cson │ │ ├── lib │ │ ├── language-crux-view.coffee │ │ └── language-crux.coffee │ │ ├── menus │ │ └── language-crux.cson │ │ ├── package.json │ │ ├── spec │ │ ├── language-crux-spec.coffee │ │ └── language-crux-view-spec.coffee │ │ └── styles │ │ └── language-crux.less └── vscode │ └── language-crux │ ├── .vscode │ └── launch.json │ ├── CHANGELOG.md │ ├── README.md │ ├── language-configuration.json │ ├── package.json │ ├── syntaxes │ └── crux.tmLanguage.json │ └── vsc-extension-quickstart.md ├── examples ├── exceptiontest.cx ├── json.cx ├── node-server │ └── main.cx ├── npmtest │ ├── .gitignore │ ├── crux.yaml │ ├── node-test.js │ ├── src │ │ ├── lib.cx │ │ └── main.cx │ ├── test.sh │ └── tests │ │ └── main.cx └── objects.cx ├── lib ├── array.cx ├── assert.cx ├── boolean.cx ├── builtin.cx ├── callbackqueue.cx ├── cmp.cx ├── dict.cx ├── dom │ ├── worker.cx │ └── workerself.cx ├── exception.cx ├── flux │ └── dispatcher.cx ├── integer.cx ├── js.cx ├── js │ ├── option.cx │ └── unsafe.cx ├── json.cx ├── length.cx ├── literal.cx ├── mutarray.cx ├── number.cx ├── operator.cx ├── option.cx ├── path.cx ├── print.cx ├── random.cx ├── range.cx ├── repr.cx ├── result.cx ├── string.cx ├── test.cx ├── test │ └── quickcheck.cx ├── tostring.cx ├── tuple.cx └── types.cx ├── rts └── rts.js ├── run ├── s ├── build-all ├── crux.inc ├── lint ├── run-all └── test ├── src ├── crux │ └── Main.hs └── hlint.hs ├── stack.yaml ├── stack.yaml.lock ├── template └── crux.yaml.template ├── test-data ├── empty.cx ├── enum.cx ├── enum2.cx ├── escapes.cx ├── export.cx ├── fib.cx ├── for-loop.cx ├── issue-51 │ ├── A.cx │ └── B.cx ├── module-qualified │ └── main.sk.disabled ├── mutable_let.cx ├── mutable_record.cx ├── mutable_record_parameter.cx ├── parameterized_type_alias.cx ├── rawjs.cx ├── records.cx ├── records2.cx ├── return-in-if.cx ├── test10.cx ├── test11.cx ├── test12.cx ├── test13.cx ├── test14.cx ├── test15.cx ├── test2.cx ├── test3.cx ├── test6.cx ├── test7.cx ├── test8.cx ├── test9.cx ├── to_option_string.cx ├── unsafecoerce.cx └── xhr │ ├── Http.cx │ ├── index.html │ └── main.cx └── tests ├── GenTest.hs ├── IntegrationTest.hs ├── IntegrationTestMain.hs ├── JSBackendTest.hs ├── ModuleTest.hs ├── ParseTest.hs ├── TypecheckTest.hs ├── UnifyTest.hs ├── UnitTestMain.hs ├── crux ├── arraytest.cx ├── booltest.cx ├── callbackqueuetest.cx ├── cmptest.cx ├── dicttest.cx ├── flux │ └── dispatchertest.cx ├── integertest.cx ├── js │ └── optiontest.cx ├── jsontest.cx ├── jstest.cx ├── main.cx ├── numbertest.cx ├── optiontest.cx ├── pathtest.cx ├── rangetest.cx ├── reprtest.cx ├── stringtest.cx ├── test │ └── quickchecktest.cx └── tostringtest.cx └── integration ├── alias-data-cycle ├── main.cx └── stdout.txt ├── arg-pattern ├── main.cx └── stdout.txt ├── arg-wildcard ├── main.cx └── stdout.txt ├── arithmetic ├── main.cx └── stdout.txt ├── array-alias ├── main.cx └── stdout.txt ├── array-iteration ├── main.cx └── stdout.txt ├── array-type-ident ├── main.cx └── stdout.txt ├── arrays ├── main.cx └── stdout.txt ├── as ├── main.cx └── stdout.txt ├── assignment ├── cannot-assign-to-immutable-field │ ├── error.yaml │ └── main.cx ├── cannot-assign-to-immutable │ ├── error.yaml │ └── main.cx └── record-field-requirement-is-inferred │ ├── error.yaml │ └── main.cx ├── basic-syntax ├── main.cx └── stdout.txt ├── boolean-expression ├── main.cx └── stdout.txt ├── comments ├── basic │ ├── main.cx │ └── stdout.txt ├── docstring │ ├── main.cx │ └── stdout.txt └── nested │ ├── main.cx │ └── stdout.txt ├── concatenate-strings ├── main.cx └── stdout.txt ├── data-shorthand ├── main.cx └── stdout.txt ├── datatypes ├── main.cx └── stdout.txt ├── errors ├── circular-imports │ ├── a.cx │ ├── b.cx │ ├── error.yaml │ └── main.cx ├── intrinsic │ ├── error.yaml │ └── main.cx ├── let-not-recursive │ ├── error.yaml │ └── main.cx ├── occurs │ ├── field │ │ ├── error.yaml │ │ └── main.cx │ ├── fun │ │ ├── error.yaml │ │ └── main.cx │ ├── record │ │ ├── error.yaml │ │ └── main.cx │ └── sum │ │ ├── error.yaml │ │ └── main.cx └── too-many-args │ ├── error.yaml │ └── main.cx ├── exceptions ├── qualified-exceptions │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── throw-and-catch │ ├── main.cx │ └── stdout.txt ├── wildcard-binding │ ├── main.cx │ └── stdout.txt └── wildcard-exceptions │ ├── main.cx │ └── stdout.txt ├── for-loop ├── array │ ├── main.cx │ └── stdout.txt └── wildcard │ ├── main.cx │ └── stdout.txt ├── hello ├── main.cx └── stdout.txt ├── if-block ├── main.cx └── stdout.txt ├── if-then-else-2 ├── main.cx └── stdout.txt ├── if-then-else-block ├── main.cx └── stdout.txt ├── if-then-else ├── main.cx └── stdout.txt ├── import-types-with-cyclic-dependencies ├── A.cx ├── main.cx └── stdout.txt ├── integer ├── main.cx └── stdout.txt ├── interior-unbound-types ├── main.cx └── stdout.txt ├── jsffi-data-types ├── main.cx └── stdout.txt ├── lambda ├── block │ ├── main.cx │ └── stdout.txt ├── curried │ ├── main.cx │ └── stdout.txt └── wildcard │ ├── main.cx │ └── stdout.txt ├── let-mutable ├── main.cx └── stdout.txt ├── let-pattern ├── main.cx └── stdout.txt ├── literals └── integer │ ├── main.cx │ └── stdout.txt ├── match ├── block │ ├── main.cx │ └── stdout.txt ├── internal-types │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── jsdata │ ├── main.cx │ └── stdout.txt ├── nested │ ├── main.cx │ └── stdout.txt ├── patterns │ ├── main.cx │ └── stdout.txt ├── qualified-pattern │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── type-error │ ├── error.yaml │ └── main.cx ├── unit │ ├── main.cx │ └── stdout.txt └── wildcard │ ├── main.cx │ └── stdout.txt ├── modules ├── export-and-import │ ├── MyModule.cx │ ├── main.cx │ └── stdout.txt ├── export-declare │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── export-import-traits │ ├── main.cx │ ├── middle.cx │ ├── stdout.txt │ └── tm.cx ├── export-import │ ├── bar.cx │ ├── foo.cx │ ├── main.cx │ └── stdout.txt ├── import-as-wildcard │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── import-as │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── lowercase-module-name │ ├── main.cx │ ├── mymodule.cx │ └── stdout.txt ├── qualified-data-constructor │ ├── m.cx │ ├── main.cx │ └── stdout.txt ├── qualified-functions-are-instantiated │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── qualified-jsdata-reference │ ├── main.cx │ └── stdout.txt ├── qualified-type │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── selective-import │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt └── using-internal-types │ ├── main.cx │ ├── mymod.cx │ └── stdout.txt ├── multiparameter-return-type ├── main.cx └── stdout.txt ├── mutable-array ├── main.cx └── stdout.txt ├── name-functions-javascript-keywords ├── main.cx └── stdout.txt ├── option-type-ident ├── main.cx └── stdout.txt ├── parameterized-type-alias ├── main.cx └── stdout.txt ├── parametric-type-annotation ├── main.cx └── stdout.txt ├── polymorphic-type-annotations-are-quantified-3 ├── main.cx └── stdout.txt ├── polymorphic-type-annotations-are-quantified-4 ├── error.yaml └── main.cx ├── polymorphic-type-annotations-are-quantified ├── main.cx └── stdout.txt ├── prelude-provides-option ├── main.cx └── stdout.txt ├── quantify-user-types ├── main.cx └── stdout.txt ├── records ├── annotation │ ├── main.cx │ └── stdout.txt ├── errors │ ├── annotation-is-checked │ │ ├── error.yaml │ │ └── main.cx │ ├── closed-and-quantified │ │ ├── error.yaml │ │ └── main.cx │ ├── quantified-constraint-incompatible │ │ ├── error.yaml │ │ └── main.cx │ ├── quantified-constraint-violation │ │ ├── error.yaml │ │ └── main.cx │ └── quantified-constraints │ │ ├── error.yaml │ │ └── main.cx ├── fields-immutable-by-default │ ├── error.yaml │ └── main.cx ├── inferred-field-accepts-mutable-or-immutable │ ├── main.cx │ └── stdout.txt ├── mutable │ ├── main.cx │ └── stdout.txt ├── optional-fields │ ├── jsoption │ │ ├── main.cx │ │ └── stdout.txt │ ├── option │ │ ├── main.cx │ │ └── stdout.txt │ └── unification │ │ ├── main.cx │ │ └── stdout.txt ├── quantified-mutability │ ├── main.cx │ └── stdout.txt ├── quantified │ ├── main.cx │ └── stdout.txt ├── row-variables-are-checked │ ├── error.yaml │ └── main.cx ├── self-unification │ ├── main.cx │ └── stdout.txt └── type-parameter │ ├── main.cx │ └── stdout.txt ├── recursive-data ├── main.cx └── stdout.txt ├── recursive ├── main.cx └── stdout.txt ├── return-type-parsing ├── main.cx └── stdout.txt ├── return-unifies-with-anything ├── main.cx └── stdout.txt ├── row-polymorphism-2 ├── main.cx └── stdout.txt ├── row-polymorphism ├── main.cx └── stdout.txt ├── scope ├── main.cx └── stdout.txt ├── string-methods ├── main.cx └── stdout.txt ├── tdnr ├── inside-each │ ├── main.cx │ └── stdout.txt ├── inside-for-loop │ ├── main.cx │ └── stdout.txt ├── inside-this-module │ ├── main.cx │ └── stdout.txt ├── quantifies-function │ ├── main.cx │ └── stdout.txt ├── type-qualified │ ├── main.cx │ └── stdout.txt └── with-arg-annotation │ ├── main.cx │ └── stdout.txt ├── top-level-function-call ├── main.cx └── stdout.txt ├── tostring ├── main.cx └── stdout.txt ├── traits ├── ambiguous-trait-name │ ├── main.cx │ ├── one.cx │ ├── stdout.txt │ └── two.cx ├── basic │ ├── main.cx │ └── stdout.txt ├── constrained-instances-2 │ ├── main.cx │ └── stdout.txt ├── constrained-instances │ ├── main.cx │ └── stdout.txt ├── defaults │ ├── main.cx │ └── stdout.txt ├── defaults_method_syntax │ ├── main.cx │ └── stdout.txt ├── defaults_must_have_correct_type │ ├── error.yaml │ └── main.cx ├── errors │ ├── duplicate-impl-method │ │ ├── error.yaml │ │ └── main.cx │ ├── duplicate-method │ │ ├── error.yaml │ │ └── main.cx │ ├── extra-method │ │ ├── error.yaml │ │ └── main.cx │ ├── impl-type │ │ ├── error.yaml │ │ └── main.cx │ ├── incomplete-impl │ │ ├── error.yaml │ │ └── main.cx │ ├── no-type-variables │ │ ├── error.yaml │ │ └── main.cx │ ├── quant-trait │ │ ├── error.yaml │ │ └── main.cx │ └── too-many-type-variables │ │ ├── error.yaml │ │ └── main.cx ├── function-impl │ ├── main.cx │ └── stdout.txt ├── impl-not-available-before-definition │ ├── error.yaml │ └── main.cx ├── impl-tdnr │ ├── main.cx │ └── stdout.txt ├── imported-trait-name │ ├── main.cx │ ├── one.cx │ ├── stdout.txt │ └── two.cx ├── let │ ├── main.cx │ └── stdout.txt ├── polymorphic-ambiguity │ ├── error.yaml │ └── main.cx ├── polymorphic-expressions │ ├── main.cx │ └── stdout.txt ├── quant │ ├── main.cx │ └── stdout.txt ├── rebound-trait-values │ ├── main.cx │ └── stdout.txt ├── record-constraints │ ├── main.cx │ └── stdout.txt ├── record-field-does-not-unify │ ├── error.yaml │ └── main.cx ├── record-field-qvar │ ├── main.cx │ └── stdout.txt ├── record-field-result-does-not-unify │ ├── error.yaml │ └── main.cx ├── record-field-traits │ ├── main.cx │ └── stdout.txt ├── record-fields │ ├── main.cx │ └── stdout.txt ├── records │ ├── main.cx │ └── stdout.txt ├── sugar │ ├── main.cx │ └── stdout.txt ├── syntax │ ├── main.cx │ └── stdout.txt └── value-elements │ ├── main.cx │ └── stdout.txt ├── tuples ├── main.cx └── stdout.txt ├── type-alias ├── main.cx └── stdout.txt ├── type-annotations ├── dict-record │ ├── main.cx │ └── stdout.txt ├── function-decls │ ├── main.cx │ └── stdout.txt ├── function-ident │ ├── main.cx │ └── stdout.txt ├── quantified-record │ ├── main.cx │ └── stdout.txt ├── trait │ ├── error.yaml │ └── main.cx ├── type-param-alias │ ├── main.cx │ └── stdout.txt └── wildcard │ ├── main.cx │ └── stdout.txt ├── unary-operators ├── negative-literal │ ├── main.cx │ └── stdout.txt └── negative-operator │ ├── main.cx │ └── stdout.txt ├── unify └── number-with-quantified │ ├── error.yaml │ └── main.cx ├── unsafe-coerce ├── main.cx └── stdout.txt ├── unsafe-js ├── main.cx └── stdout.txt ├── weak-polymorphism ├── array │ ├── error.yaml │ └── main.cx ├── letmut │ ├── error.yaml │ └── main.cx └── record │ ├── error.yaml │ └── main.cx ├── while-loops ├── main.cx └── stdout.txt └── wildcard-function-arguments ├── main.cx └── stdout.txt /.gitattributes: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/.gitattributes -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/.gitignore -------------------------------------------------------------------------------- /.stylish-haskell.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/.stylish-haskell.yaml -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/.travis.yml -------------------------------------------------------------------------------- /Crux/AST.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/AST.hs -------------------------------------------------------------------------------- /Crux/Error.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Error.hs -------------------------------------------------------------------------------- /Crux/Gen.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Gen.hs -------------------------------------------------------------------------------- /Crux/HashTable.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/HashTable.hs -------------------------------------------------------------------------------- /Crux/IORef.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/IORef.hs -------------------------------------------------------------------------------- /Crux/JSBackend.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/JSBackend.hs -------------------------------------------------------------------------------- /Crux/JSTree.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/JSTree.hs -------------------------------------------------------------------------------- /Crux/Lex.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Lex.hs -------------------------------------------------------------------------------- /Crux/Main.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Main.hs -------------------------------------------------------------------------------- /Crux/Module.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Module.hs -------------------------------------------------------------------------------- /Crux/Module/Types.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Module/Types.hs -------------------------------------------------------------------------------- /Crux/ModuleName.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/ModuleName.hs -------------------------------------------------------------------------------- /Crux/Parse.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Parse.hs -------------------------------------------------------------------------------- /Crux/Pos.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Pos.hs -------------------------------------------------------------------------------- /Crux/Prelude.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Prelude.hs -------------------------------------------------------------------------------- /Crux/Project.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Project.hs -------------------------------------------------------------------------------- /Crux/SymbolTable.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/SymbolTable.hs -------------------------------------------------------------------------------- /Crux/Text.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Text.hs -------------------------------------------------------------------------------- /Crux/Tokens.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Tokens.hs -------------------------------------------------------------------------------- /Crux/TrackIO.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/TrackIO.hs -------------------------------------------------------------------------------- /Crux/TypeVar.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/TypeVar.hs -------------------------------------------------------------------------------- /Crux/Typecheck.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Env.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Env.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Inst.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Inst.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Monad.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Monad.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Occurs.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Occurs.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Quantify.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Quantify.hs -------------------------------------------------------------------------------- /Crux/Typecheck/TypeAlloc.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/TypeAlloc.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Types.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Types.hs -------------------------------------------------------------------------------- /Crux/Typecheck/Unify.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Typecheck/Unify.hs -------------------------------------------------------------------------------- /Crux/Util.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/Crux/Util.hs -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/LICENSE.txt -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/README.md -------------------------------------------------------------------------------- /Setup.hs: -------------------------------------------------------------------------------- 1 | import Distribution.Simple 2 | main = defaultMain 3 | -------------------------------------------------------------------------------- /closure-service/.gitignore: -------------------------------------------------------------------------------- 1 | target 2 | .env 3 | .idea/ 4 | *.iml 5 | -------------------------------------------------------------------------------- /closure-service/.mvn/wrapper/maven-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/.mvn/wrapper/maven-wrapper.jar -------------------------------------------------------------------------------- /closure-service/.mvn/wrapper/maven-wrapper.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/.mvn/wrapper/maven-wrapper.properties -------------------------------------------------------------------------------- /closure-service/LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/LICENSE -------------------------------------------------------------------------------- /closure-service/Procfile: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/Procfile -------------------------------------------------------------------------------- /closure-service/Procfile.windows: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/Procfile.windows -------------------------------------------------------------------------------- /closure-service/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/README.md -------------------------------------------------------------------------------- /closure-service/app.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/app.json -------------------------------------------------------------------------------- /closure-service/mvnw: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/mvnw -------------------------------------------------------------------------------- /closure-service/mvnw.cmd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/mvnw.cmd -------------------------------------------------------------------------------- /closure-service/pom.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/pom.xml -------------------------------------------------------------------------------- /closure-service/src/main/java/Main.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/closure-service/src/main/java/Main.java -------------------------------------------------------------------------------- /closure-service/system.properties: -------------------------------------------------------------------------------- 1 | java.runtime.version=11 2 | 3 | -------------------------------------------------------------------------------- /crux.cabal: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/crux.cabal -------------------------------------------------------------------------------- /crux.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/crux.yaml -------------------------------------------------------------------------------- /cruxjs/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/.gitignore -------------------------------------------------------------------------------- /cruxjs/LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/LICENSE -------------------------------------------------------------------------------- /cruxjs/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/README.md -------------------------------------------------------------------------------- /cruxjs/Setup.hs: -------------------------------------------------------------------------------- 1 | import Distribution.Simple 2 | main = defaultMain 3 | -------------------------------------------------------------------------------- /cruxjs/crux.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/crux.yaml -------------------------------------------------------------------------------- /cruxjs/cruxjs.cabal: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/cruxjs.cabal -------------------------------------------------------------------------------- /cruxjs/jsbits/wrap.intro.js: -------------------------------------------------------------------------------- 1 | (function(global) { 2 | -------------------------------------------------------------------------------- /cruxjs/jsbits/wrap.outro.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/jsbits/wrap.outro.js -------------------------------------------------------------------------------- /cruxjs/npm/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/npm/.gitignore -------------------------------------------------------------------------------- /cruxjs/npm/cruxlang/cli.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/npm/cruxlang/cli.js -------------------------------------------------------------------------------- /cruxjs/npm/cruxlang/package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/npm/cruxlang/package.json -------------------------------------------------------------------------------- /cruxjs/s/build: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/s/build -------------------------------------------------------------------------------- /cruxjs/s/sass-watcher: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/s/sass-watcher -------------------------------------------------------------------------------- /cruxjs/s/server: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e 4 | 5 | (cd stage && python -m SimpleHTTPServer 8080) 6 | -------------------------------------------------------------------------------- /cruxjs/src/Main.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/src/Main.hs -------------------------------------------------------------------------------- /cruxjs/src/compiler-worker.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/src/compiler-worker.cx -------------------------------------------------------------------------------- /cruxjs/src/crux.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/src/crux.cx -------------------------------------------------------------------------------- /cruxjs/src/playground.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/src/playground.cx -------------------------------------------------------------------------------- /cruxjs/stack.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/stack.yaml -------------------------------------------------------------------------------- /cruxjs/stage/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/stage/index.html -------------------------------------------------------------------------------- /cruxjs/stage/style.scss: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cruxjs/stage/style.scss -------------------------------------------------------------------------------- /cxconfig.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/cxconfig.yaml -------------------------------------------------------------------------------- /doc/design/angle-brackets.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/angle-brackets.md -------------------------------------------------------------------------------- /doc/design/arrays.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/arrays.md -------------------------------------------------------------------------------- /doc/design/case.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/case.md -------------------------------------------------------------------------------- /doc/design/cli.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/cli.md -------------------------------------------------------------------------------- /doc/design/exceptions.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/exceptions.md -------------------------------------------------------------------------------- /doc/design/ffi.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/ffi.md -------------------------------------------------------------------------------- /doc/design/for-loops.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/for-loops.md -------------------------------------------------------------------------------- /doc/design/hypotheses.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/hypotheses.md -------------------------------------------------------------------------------- /doc/design/language-references.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/language-references.md -------------------------------------------------------------------------------- /doc/design/layout.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/layout.md -------------------------------------------------------------------------------- /doc/design/letrec.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/letrec.md -------------------------------------------------------------------------------- /doc/design/methods.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/methods.md -------------------------------------------------------------------------------- /doc/design/modules.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/modules.md -------------------------------------------------------------------------------- /doc/design/mutability.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/mutability.md -------------------------------------------------------------------------------- /doc/design/names.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/names.md -------------------------------------------------------------------------------- /doc/design/namespaces.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/namespaces.md -------------------------------------------------------------------------------- /doc/design/npm-integration.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/npm-integration.md -------------------------------------------------------------------------------- /doc/design/objects.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/objects.md -------------------------------------------------------------------------------- /doc/design/option.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/option.md -------------------------------------------------------------------------------- /doc/design/positioning.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/positioning.md -------------------------------------------------------------------------------- /doc/design/precedence.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/precedence.md -------------------------------------------------------------------------------- /doc/design/record-traits.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/record-traits.md -------------------------------------------------------------------------------- /doc/design/records-with-optional-fields.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/records-with-optional-fields.md -------------------------------------------------------------------------------- /doc/design/records.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/records.md -------------------------------------------------------------------------------- /doc/design/row-polymorphism-unification.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/row-polymorphism-unification.md -------------------------------------------------------------------------------- /doc/design/strings.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/strings.md -------------------------------------------------------------------------------- /doc/design/style.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/style.md -------------------------------------------------------------------------------- /doc/design/sugar.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/sugar.md -------------------------------------------------------------------------------- /doc/design/traits.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/traits.md -------------------------------------------------------------------------------- /doc/design/unification-table.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/design/unification-table.md -------------------------------------------------------------------------------- /doc/tutorial/writing-npm-module.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/doc/tutorial/writing-npm-module.md -------------------------------------------------------------------------------- /editor-support/atom/language-crux/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | npm-debug.log 3 | node_modules 4 | -------------------------------------------------------------------------------- /editor-support/atom/language-crux/CHANGELOG.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/CHANGELOG.md -------------------------------------------------------------------------------- /editor-support/atom/language-crux/LICENSE.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/LICENSE.md -------------------------------------------------------------------------------- /editor-support/atom/language-crux/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/README.md -------------------------------------------------------------------------------- /editor-support/atom/language-crux/grammars/crux.cson: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/grammars/crux.cson -------------------------------------------------------------------------------- /editor-support/atom/language-crux/keymaps/language-crux.cson: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/keymaps/language-crux.cson -------------------------------------------------------------------------------- /editor-support/atom/language-crux/lib/language-crux-view.coffee: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/lib/language-crux-view.coffee -------------------------------------------------------------------------------- /editor-support/atom/language-crux/lib/language-crux.coffee: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/lib/language-crux.coffee -------------------------------------------------------------------------------- /editor-support/atom/language-crux/menus/language-crux.cson: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/menus/language-crux.cson -------------------------------------------------------------------------------- /editor-support/atom/language-crux/package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/package.json -------------------------------------------------------------------------------- /editor-support/atom/language-crux/spec/language-crux-spec.coffee: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/spec/language-crux-spec.coffee -------------------------------------------------------------------------------- /editor-support/atom/language-crux/spec/language-crux-view-spec.coffee: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/spec/language-crux-view-spec.coffee -------------------------------------------------------------------------------- /editor-support/atom/language-crux/styles/language-crux.less: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/atom/language-crux/styles/language-crux.less -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/.vscode/launch.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/.vscode/launch.json -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/CHANGELOG.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/CHANGELOG.md -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/README.md -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/language-configuration.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/language-configuration.json -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/package.json -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/syntaxes/crux.tmLanguage.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/syntaxes/crux.tmLanguage.json -------------------------------------------------------------------------------- /editor-support/vscode/language-crux/vsc-extension-quickstart.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/editor-support/vscode/language-crux/vsc-extension-quickstart.md -------------------------------------------------------------------------------- /examples/exceptiontest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/exceptiontest.cx -------------------------------------------------------------------------------- /examples/json.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/json.cx -------------------------------------------------------------------------------- /examples/node-server/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/node-server/main.cx -------------------------------------------------------------------------------- /examples/npmtest/.gitignore: -------------------------------------------------------------------------------- 1 | /build/ 2 | -------------------------------------------------------------------------------- /examples/npmtest/crux.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/npmtest/crux.yaml -------------------------------------------------------------------------------- /examples/npmtest/node-test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/npmtest/node-test.js -------------------------------------------------------------------------------- /examples/npmtest/src/lib.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/npmtest/src/lib.cx -------------------------------------------------------------------------------- /examples/npmtest/src/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/npmtest/src/main.cx -------------------------------------------------------------------------------- /examples/npmtest/test.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/npmtest/test.sh -------------------------------------------------------------------------------- /examples/npmtest/tests/main.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | } 3 | -------------------------------------------------------------------------------- /examples/objects.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/examples/objects.cx -------------------------------------------------------------------------------- /lib/array.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/array.cx -------------------------------------------------------------------------------- /lib/assert.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/assert.cx -------------------------------------------------------------------------------- /lib/boolean.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/boolean.cx -------------------------------------------------------------------------------- /lib/builtin.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/builtin.cx -------------------------------------------------------------------------------- /lib/callbackqueue.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/callbackqueue.cx -------------------------------------------------------------------------------- /lib/cmp.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/cmp.cx -------------------------------------------------------------------------------- /lib/dict.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/dict.cx -------------------------------------------------------------------------------- /lib/dom/worker.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/dom/worker.cx -------------------------------------------------------------------------------- /lib/dom/workerself.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/dom/workerself.cx -------------------------------------------------------------------------------- /lib/exception.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/exception.cx -------------------------------------------------------------------------------- /lib/flux/dispatcher.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/flux/dispatcher.cx -------------------------------------------------------------------------------- /lib/integer.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/integer.cx -------------------------------------------------------------------------------- /lib/js.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/js.cx -------------------------------------------------------------------------------- /lib/js/option.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/js/option.cx -------------------------------------------------------------------------------- /lib/js/unsafe.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/js/unsafe.cx -------------------------------------------------------------------------------- /lib/json.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/json.cx -------------------------------------------------------------------------------- /lib/length.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/length.cx -------------------------------------------------------------------------------- /lib/literal.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/literal.cx -------------------------------------------------------------------------------- /lib/mutarray.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/mutarray.cx -------------------------------------------------------------------------------- /lib/number.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/number.cx -------------------------------------------------------------------------------- /lib/operator.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/operator.cx -------------------------------------------------------------------------------- /lib/option.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/option.cx -------------------------------------------------------------------------------- /lib/path.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/path.cx -------------------------------------------------------------------------------- /lib/print.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/print.cx -------------------------------------------------------------------------------- /lib/random.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/random.cx -------------------------------------------------------------------------------- /lib/range.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/range.cx -------------------------------------------------------------------------------- /lib/repr.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/repr.cx -------------------------------------------------------------------------------- /lib/result.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/result.cx -------------------------------------------------------------------------------- /lib/string.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/string.cx -------------------------------------------------------------------------------- /lib/test.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/test.cx -------------------------------------------------------------------------------- /lib/test/quickcheck.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/test/quickcheck.cx -------------------------------------------------------------------------------- /lib/tostring.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/tostring.cx -------------------------------------------------------------------------------- /lib/tuple.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/tuple.cx -------------------------------------------------------------------------------- /lib/types.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/lib/types.cx -------------------------------------------------------------------------------- /rts/rts.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/rts/rts.js -------------------------------------------------------------------------------- /run: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/run -------------------------------------------------------------------------------- /s/build-all: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/s/build-all -------------------------------------------------------------------------------- /s/crux.inc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/s/crux.inc -------------------------------------------------------------------------------- /s/lint: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/s/lint -------------------------------------------------------------------------------- /s/run-all: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/s/run-all -------------------------------------------------------------------------------- /s/test: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/s/test -------------------------------------------------------------------------------- /src/crux/Main.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/src/crux/Main.hs -------------------------------------------------------------------------------- /src/hlint.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/src/hlint.hs -------------------------------------------------------------------------------- /stack.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/stack.yaml -------------------------------------------------------------------------------- /stack.yaml.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/stack.yaml.lock -------------------------------------------------------------------------------- /template/crux.yaml.template: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/template/crux.yaml.template -------------------------------------------------------------------------------- /test-data/empty.cx: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /test-data/enum.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/enum.cx -------------------------------------------------------------------------------- /test-data/enum2.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/enum2.cx -------------------------------------------------------------------------------- /test-data/escapes.cx: -------------------------------------------------------------------------------- 1 | let _ = print("\0\a\b\f\n\r\t\v\\\'\"\?") 2 | -------------------------------------------------------------------------------- /test-data/export.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/export.cx -------------------------------------------------------------------------------- /test-data/fib.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/fib.cx -------------------------------------------------------------------------------- /test-data/for-loop.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/for-loop.cx -------------------------------------------------------------------------------- /test-data/issue-51/A.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/issue-51/A.cx -------------------------------------------------------------------------------- /test-data/issue-51/B.cx: -------------------------------------------------------------------------------- 1 | import {A(...)} 2 | -------------------------------------------------------------------------------- /test-data/module-qualified/main.sk.disabled: -------------------------------------------------------------------------------- 1 | import { 2 | T 3 | } 4 | 5 | let _ = print(T.f(1, 2)) 6 | -------------------------------------------------------------------------------- /test-data/mutable_let.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/mutable_let.cx -------------------------------------------------------------------------------- /test-data/mutable_record.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/mutable_record.cx -------------------------------------------------------------------------------- /test-data/mutable_record_parameter.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/mutable_record_parameter.cx -------------------------------------------------------------------------------- /test-data/parameterized_type_alias.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/parameterized_type_alias.cx -------------------------------------------------------------------------------- /test-data/rawjs.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/rawjs.cx -------------------------------------------------------------------------------- /test-data/records.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/records.cx -------------------------------------------------------------------------------- /test-data/records2.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/records2.cx -------------------------------------------------------------------------------- /test-data/return-in-if.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/return-in-if.cx -------------------------------------------------------------------------------- /test-data/test10.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test10.cx -------------------------------------------------------------------------------- /test-data/test11.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test11.cx -------------------------------------------------------------------------------- /test-data/test12.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test12.cx -------------------------------------------------------------------------------- /test-data/test13.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test13.cx -------------------------------------------------------------------------------- /test-data/test14.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | if True then print("yes") else return () 3 | } 4 | -------------------------------------------------------------------------------- /test-data/test15.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test15.cx -------------------------------------------------------------------------------- /test-data/test2.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test2.cx -------------------------------------------------------------------------------- /test-data/test3.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test3.cx -------------------------------------------------------------------------------- /test-data/test6.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test6.cx -------------------------------------------------------------------------------- /test-data/test7.cx: -------------------------------------------------------------------------------- 1 | let _ = 5 * 5 2 | -------------------------------------------------------------------------------- /test-data/test8.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test8.cx -------------------------------------------------------------------------------- /test-data/test9.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/test9.cx -------------------------------------------------------------------------------- /test-data/to_option_string.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/to_option_string.cx -------------------------------------------------------------------------------- /test-data/unsafecoerce.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/unsafecoerce.cx -------------------------------------------------------------------------------- /test-data/xhr/Http.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/xhr/Http.cx -------------------------------------------------------------------------------- /test-data/xhr/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/xhr/index.html -------------------------------------------------------------------------------- /test-data/xhr/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/test-data/xhr/main.cx -------------------------------------------------------------------------------- /tests/GenTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/GenTest.hs -------------------------------------------------------------------------------- /tests/IntegrationTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/IntegrationTest.hs -------------------------------------------------------------------------------- /tests/IntegrationTestMain.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/IntegrationTestMain.hs -------------------------------------------------------------------------------- /tests/JSBackendTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/JSBackendTest.hs -------------------------------------------------------------------------------- /tests/ModuleTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/ModuleTest.hs -------------------------------------------------------------------------------- /tests/ParseTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/ParseTest.hs -------------------------------------------------------------------------------- /tests/TypecheckTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/TypecheckTest.hs -------------------------------------------------------------------------------- /tests/UnifyTest.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/UnifyTest.hs -------------------------------------------------------------------------------- /tests/UnitTestMain.hs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/UnitTestMain.hs -------------------------------------------------------------------------------- /tests/crux/arraytest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/arraytest.cx -------------------------------------------------------------------------------- /tests/crux/booltest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/booltest.cx -------------------------------------------------------------------------------- /tests/crux/callbackqueuetest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/callbackqueuetest.cx -------------------------------------------------------------------------------- /tests/crux/cmptest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/cmptest.cx -------------------------------------------------------------------------------- /tests/crux/dicttest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/dicttest.cx -------------------------------------------------------------------------------- /tests/crux/flux/dispatchertest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/flux/dispatchertest.cx -------------------------------------------------------------------------------- /tests/crux/integertest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/integertest.cx -------------------------------------------------------------------------------- /tests/crux/js/optiontest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/js/optiontest.cx -------------------------------------------------------------------------------- /tests/crux/jsontest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/jsontest.cx -------------------------------------------------------------------------------- /tests/crux/jstest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/jstest.cx -------------------------------------------------------------------------------- /tests/crux/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/main.cx -------------------------------------------------------------------------------- /tests/crux/numbertest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/numbertest.cx -------------------------------------------------------------------------------- /tests/crux/optiontest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/optiontest.cx -------------------------------------------------------------------------------- /tests/crux/pathtest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/pathtest.cx -------------------------------------------------------------------------------- /tests/crux/rangetest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/rangetest.cx -------------------------------------------------------------------------------- /tests/crux/reprtest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/reprtest.cx -------------------------------------------------------------------------------- /tests/crux/stringtest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/stringtest.cx -------------------------------------------------------------------------------- /tests/crux/test/quickchecktest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/test/quickchecktest.cx -------------------------------------------------------------------------------- /tests/crux/tostringtest.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/crux/tostringtest.cx -------------------------------------------------------------------------------- /tests/integration/alias-data-cycle/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/alias-data-cycle/main.cx -------------------------------------------------------------------------------- /tests/integration/alias-data-cycle/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/arg-pattern/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/arg-pattern/main.cx -------------------------------------------------------------------------------- /tests/integration/arg-pattern/stdout.txt: -------------------------------------------------------------------------------- 1 | Hello 2 | further 3 | -------------------------------------------------------------------------------- /tests/integration/arg-wildcard/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/arg-wildcard/main.cx -------------------------------------------------------------------------------- /tests/integration/arg-wildcard/stdout.txt: -------------------------------------------------------------------------------- 1 | two wildcards 2 | -------------------------------------------------------------------------------- /tests/integration/arithmetic/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/arithmetic/main.cx -------------------------------------------------------------------------------- /tests/integration/arithmetic/stdout.txt: -------------------------------------------------------------------------------- 1 | 25 2 | -------------------------------------------------------------------------------- /tests/integration/array-alias/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/array-alias/main.cx -------------------------------------------------------------------------------- /tests/integration/array-alias/stdout.txt: -------------------------------------------------------------------------------- 1 | here you go 2 | -------------------------------------------------------------------------------- /tests/integration/array-iteration/main.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | each([0 as Number, 1], print) 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/array-iteration/stdout.txt: -------------------------------------------------------------------------------- 1 | 0 2 | 1 3 | -------------------------------------------------------------------------------- /tests/integration/array-type-ident/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/array-type-ident/main.cx -------------------------------------------------------------------------------- /tests/integration/array-type-ident/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/arrays/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/arrays/main.cx -------------------------------------------------------------------------------- /tests/integration/arrays/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/arrays/stdout.txt -------------------------------------------------------------------------------- /tests/integration/as/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/as/main.cx -------------------------------------------------------------------------------- /tests/integration/as/stdout.txt: -------------------------------------------------------------------------------- 1 | none 2 | -------------------------------------------------------------------------------- /tests/integration/assignment/cannot-assign-to-immutable-field/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: record-mutability-unification 2 | -------------------------------------------------------------------------------- /tests/integration/assignment/cannot-assign-to-immutable-field/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/assignment/cannot-assign-to-immutable-field/main.cx -------------------------------------------------------------------------------- /tests/integration/assignment/cannot-assign-to-immutable/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: immutable-assignment 2 | -------------------------------------------------------------------------------- /tests/integration/assignment/cannot-assign-to-immutable/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/assignment/cannot-assign-to-immutable/main.cx -------------------------------------------------------------------------------- /tests/integration/assignment/record-field-requirement-is-inferred/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: record-mutability-unification 2 | -------------------------------------------------------------------------------- /tests/integration/assignment/record-field-requirement-is-inferred/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/assignment/record-field-requirement-is-inferred/main.cx -------------------------------------------------------------------------------- /tests/integration/basic-syntax/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/basic-syntax/main.cx -------------------------------------------------------------------------------- /tests/integration/basic-syntax/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/basic-syntax/stdout.txt -------------------------------------------------------------------------------- /tests/integration/boolean-expression/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/boolean-expression/main.cx -------------------------------------------------------------------------------- /tests/integration/boolean-expression/stdout.txt: -------------------------------------------------------------------------------- 1 | true 2 | -------------------------------------------------------------------------------- /tests/integration/comments/basic/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/comments/basic/main.cx -------------------------------------------------------------------------------- /tests/integration/comments/basic/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/comments/docstring/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/comments/docstring/main.cx -------------------------------------------------------------------------------- /tests/integration/comments/docstring/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/comments/nested/main.cx: -------------------------------------------------------------------------------- 1 | /* /* foo */ */ 2 | fun main() {} 3 | -------------------------------------------------------------------------------- /tests/integration/comments/nested/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/concatenate-strings/main.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | print("foo" + "bar") 3 | } -------------------------------------------------------------------------------- /tests/integration/concatenate-strings/stdout.txt: -------------------------------------------------------------------------------- 1 | foobar 2 | -------------------------------------------------------------------------------- /tests/integration/data-shorthand/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/data-shorthand/main.cx -------------------------------------------------------------------------------- /tests/integration/data-shorthand/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/datatypes/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/datatypes/main.cx -------------------------------------------------------------------------------- /tests/integration/datatypes/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/datatypes/stdout.txt -------------------------------------------------------------------------------- /tests/integration/errors/circular-imports/a.cx: -------------------------------------------------------------------------------- 1 | import b 2 | -------------------------------------------------------------------------------- /tests/integration/errors/circular-imports/b.cx: -------------------------------------------------------------------------------- 1 | import a 2 | -------------------------------------------------------------------------------- /tests/integration/errors/circular-imports/error.yaml: -------------------------------------------------------------------------------- 1 | error-name: circular-import 2 | -------------------------------------------------------------------------------- /tests/integration/errors/circular-imports/main.cx: -------------------------------------------------------------------------------- 1 | import a 2 | -------------------------------------------------------------------------------- /tests/integration/errors/intrinsic/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: intrinsic 2 | -------------------------------------------------------------------------------- /tests/integration/errors/intrinsic/main.cx: -------------------------------------------------------------------------------- 1 | let bad = _unsafe_js 2 | -------------------------------------------------------------------------------- /tests/integration/errors/let-not-recursive/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unbound-value 2 | -------------------------------------------------------------------------------- /tests/integration/errors/let-not-recursive/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/errors/let-not-recursive/main.cx -------------------------------------------------------------------------------- /tests/integration/errors/occurs/field/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: occurs-check 2 | -------------------------------------------------------------------------------- /tests/integration/errors/occurs/field/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/errors/occurs/field/main.cx -------------------------------------------------------------------------------- /tests/integration/errors/occurs/fun/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: occurs-check 2 | -------------------------------------------------------------------------------- /tests/integration/errors/occurs/fun/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/errors/occurs/fun/main.cx -------------------------------------------------------------------------------- /tests/integration/errors/occurs/record/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: occurs-check 2 | -------------------------------------------------------------------------------- /tests/integration/errors/occurs/record/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/errors/occurs/record/main.cx -------------------------------------------------------------------------------- /tests/integration/errors/occurs/sum/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: occurs-check 2 | -------------------------------------------------------------------------------- /tests/integration/errors/occurs/sum/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/errors/occurs/sum/main.cx -------------------------------------------------------------------------------- /tests/integration/errors/too-many-args/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/errors/too-many-args/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/errors/too-many-args/main.cx -------------------------------------------------------------------------------- /tests/integration/exceptions/qualified-exceptions/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/exceptions/qualified-exceptions/main.cx -------------------------------------------------------------------------------- /tests/integration/exceptions/qualified-exceptions/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/exceptions/qualified-exceptions/mymod.cx -------------------------------------------------------------------------------- /tests/integration/exceptions/qualified-exceptions/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/exceptions/qualified-exceptions/stdout.txt -------------------------------------------------------------------------------- /tests/integration/exceptions/throw-and-catch/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/exceptions/throw-and-catch/main.cx -------------------------------------------------------------------------------- /tests/integration/exceptions/throw-and-catch/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/exceptions/wildcard-binding/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/exceptions/wildcard-binding/main.cx -------------------------------------------------------------------------------- /tests/integration/exceptions/wildcard-binding/stdout.txt: -------------------------------------------------------------------------------- 1 | caught 2 | -------------------------------------------------------------------------------- /tests/integration/exceptions/wildcard-exceptions/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/exceptions/wildcard-exceptions/main.cx -------------------------------------------------------------------------------- /tests/integration/exceptions/wildcard-exceptions/stdout.txt: -------------------------------------------------------------------------------- 1 | caught 2 | -------------------------------------------------------------------------------- /tests/integration/for-loop/array/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/for-loop/array/main.cx -------------------------------------------------------------------------------- /tests/integration/for-loop/array/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | 3 4 | -------------------------------------------------------------------------------- /tests/integration/for-loop/wildcard/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/for-loop/wildcard/main.cx -------------------------------------------------------------------------------- /tests/integration/for-loop/wildcard/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/for-loop/wildcard/stdout.txt -------------------------------------------------------------------------------- /tests/integration/hello/main.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | print("Hello, World!") 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/hello/stdout.txt: -------------------------------------------------------------------------------- 1 | Hello, World! 2 | -------------------------------------------------------------------------------- /tests/integration/if-block/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/if-block/main.cx -------------------------------------------------------------------------------- /tests/integration/if-block/stdout.txt: -------------------------------------------------------------------------------- 1 | yay 2 | -------------------------------------------------------------------------------- /tests/integration/if-then-else-2/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/if-then-else-2/main.cx -------------------------------------------------------------------------------- /tests/integration/if-then-else-2/stdout.txt: -------------------------------------------------------------------------------- 1 | Three 2 | -------------------------------------------------------------------------------- /tests/integration/if-then-else-block/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/if-then-else-block/main.cx -------------------------------------------------------------------------------- /tests/integration/if-then-else-block/stdout.txt: -------------------------------------------------------------------------------- 1 | yay 2 | -------------------------------------------------------------------------------- /tests/integration/if-then-else/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/if-then-else/main.cx -------------------------------------------------------------------------------- /tests/integration/if-then-else/stdout.txt: -------------------------------------------------------------------------------- 1 | Falso! 2 | -------------------------------------------------------------------------------- /tests/integration/import-types-with-cyclic-dependencies/A.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/import-types-with-cyclic-dependencies/A.cx -------------------------------------------------------------------------------- /tests/integration/import-types-with-cyclic-dependencies/main.cx: -------------------------------------------------------------------------------- 1 | import A(...) 2 | let a = A(B(NA)) 3 | 4 | fun main() {} 5 | -------------------------------------------------------------------------------- /tests/integration/import-types-with-cyclic-dependencies/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/integer/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/integer/main.cx -------------------------------------------------------------------------------- /tests/integration/integer/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | -------------------------------------------------------------------------------- /tests/integration/interior-unbound-types/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/interior-unbound-types/main.cx -------------------------------------------------------------------------------- /tests/integration/interior-unbound-types/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/jsffi-data-types/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/jsffi-data-types/main.cx -------------------------------------------------------------------------------- /tests/integration/jsffi-data-types/stdout.txt: -------------------------------------------------------------------------------- 1 | GET 2 | -------------------------------------------------------------------------------- /tests/integration/lambda/block/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/lambda/block/main.cx -------------------------------------------------------------------------------- /tests/integration/lambda/block/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/lambda/block/stdout.txt -------------------------------------------------------------------------------- /tests/integration/lambda/curried/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/lambda/curried/main.cx -------------------------------------------------------------------------------- /tests/integration/lambda/curried/stdout.txt: -------------------------------------------------------------------------------- 1 | 3 2 | 3 3 | 9 4 | -------------------------------------------------------------------------------- /tests/integration/lambda/wildcard/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/lambda/wildcard/main.cx -------------------------------------------------------------------------------- /tests/integration/lambda/wildcard/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/let-mutable/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/let-mutable/main.cx -------------------------------------------------------------------------------- /tests/integration/let-mutable/stdout.txt: -------------------------------------------------------------------------------- 1 | 3 2 | -------------------------------------------------------------------------------- /tests/integration/let-pattern/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/let-pattern/main.cx -------------------------------------------------------------------------------- /tests/integration/let-pattern/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/literals/integer/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/literals/integer/main.cx -------------------------------------------------------------------------------- /tests/integration/literals/integer/stdout.txt: -------------------------------------------------------------------------------- 1 | 255 2 | -255 3 | -------------------------------------------------------------------------------- /tests/integration/match/block/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/block/main.cx -------------------------------------------------------------------------------- /tests/integration/match/block/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/match/internal-types/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/internal-types/main.cx -------------------------------------------------------------------------------- /tests/integration/match/internal-types/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/internal-types/mymod.cx -------------------------------------------------------------------------------- /tests/integration/match/internal-types/stdout.txt: -------------------------------------------------------------------------------- 1 | hello 2 | -------------------------------------------------------------------------------- /tests/integration/match/jsdata/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/jsdata/main.cx -------------------------------------------------------------------------------- /tests/integration/match/jsdata/stdout.txt: -------------------------------------------------------------------------------- 1 | true 2 | -------------------------------------------------------------------------------- /tests/integration/match/nested/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/nested/main.cx -------------------------------------------------------------------------------- /tests/integration/match/nested/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | -------------------------------------------------------------------------------- /tests/integration/match/patterns/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/patterns/main.cx -------------------------------------------------------------------------------- /tests/integration/match/patterns/stdout.txt: -------------------------------------------------------------------------------- 1 | 2 2 | -------------------------------------------------------------------------------- /tests/integration/match/qualified-pattern/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/qualified-pattern/main.cx -------------------------------------------------------------------------------- /tests/integration/match/qualified-pattern/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/qualified-pattern/mymod.cx -------------------------------------------------------------------------------- /tests/integration/match/qualified-pattern/stdout.txt: -------------------------------------------------------------------------------- 1 | red 2 | -------------------------------------------------------------------------------- /tests/integration/match/type-error/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/match/type-error/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/type-error/main.cx -------------------------------------------------------------------------------- /tests/integration/match/unit/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/unit/main.cx -------------------------------------------------------------------------------- /tests/integration/match/unit/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | -------------------------------------------------------------------------------- /tests/integration/match/wildcard/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/match/wildcard/main.cx -------------------------------------------------------------------------------- /tests/integration/match/wildcard/stdout.txt: -------------------------------------------------------------------------------- 1 | none 2 | -------------------------------------------------------------------------------- /tests/integration/modules/export-and-import/MyModule.cx: -------------------------------------------------------------------------------- 1 | export fun fn() { 2 | print("inside") 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/modules/export-and-import/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-and-import/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-and-import/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-and-import/stdout.txt -------------------------------------------------------------------------------- /tests/integration/modules/export-declare/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-declare/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-declare/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-declare/mymod.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-declare/stdout.txt: -------------------------------------------------------------------------------- 1 | 12 2 | -------------------------------------------------------------------------------- /tests/integration/modules/export-import-traits/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-import-traits/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-import-traits/middle.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-import-traits/middle.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-import-traits/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/modules/export-import-traits/tm.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-import-traits/tm.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-import/bar.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-import/bar.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-import/foo.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-import/foo.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-import/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/export-import/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/export-import/stdout.txt: -------------------------------------------------------------------------------- 1 | Foo 2 | -------------------------------------------------------------------------------- /tests/integration/modules/import-as-wildcard/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/import-as-wildcard/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/import-as-wildcard/mymod.cx: -------------------------------------------------------------------------------- 1 | let _ = print("in mymod") -------------------------------------------------------------------------------- /tests/integration/modules/import-as-wildcard/stdout.txt: -------------------------------------------------------------------------------- 1 | in mymod 2 | in main 3 | -------------------------------------------------------------------------------- /tests/integration/modules/import-as/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/import-as/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/import-as/mymod.cx: -------------------------------------------------------------------------------- 1 | export fun main() { 2 | print("mymod?") 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/modules/import-as/stdout.txt: -------------------------------------------------------------------------------- 1 | mymod? 2 | -------------------------------------------------------------------------------- /tests/integration/modules/lowercase-module-name/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/lowercase-module-name/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/lowercase-module-name/mymodule.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/lowercase-module-name/mymodule.cx -------------------------------------------------------------------------------- /tests/integration/modules/lowercase-module-name/stdout.txt: -------------------------------------------------------------------------------- 1 | thing 2 | -------------------------------------------------------------------------------- /tests/integration/modules/qualified-data-constructor/m.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-data-constructor/m.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-data-constructor/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-data-constructor/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-data-constructor/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-data-constructor/stdout.txt -------------------------------------------------------------------------------- /tests/integration/modules/qualified-functions-are-instantiated/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-functions-are-instantiated/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-functions-are-instantiated/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-functions-are-instantiated/mymod.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-functions-are-instantiated/stdout.txt: -------------------------------------------------------------------------------- 1 | 3 2 | -------------------------------------------------------------------------------- /tests/integration/modules/qualified-jsdata-reference/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-jsdata-reference/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-jsdata-reference/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/modules/qualified-type/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-type/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-type/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/qualified-type/mymod.cx -------------------------------------------------------------------------------- /tests/integration/modules/qualified-type/stdout.txt: -------------------------------------------------------------------------------- 1 | runDT 2 | -------------------------------------------------------------------------------- /tests/integration/modules/selective-import/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/selective-import/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/selective-import/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/selective-import/mymod.cx -------------------------------------------------------------------------------- /tests/integration/modules/selective-import/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /tests/integration/modules/using-internal-types/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/using-internal-types/main.cx -------------------------------------------------------------------------------- /tests/integration/modules/using-internal-types/mymod.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/modules/using-internal-types/mymod.cx -------------------------------------------------------------------------------- /tests/integration/modules/using-internal-types/stdout.txt: -------------------------------------------------------------------------------- 1 | hi 2 | -------------------------------------------------------------------------------- /tests/integration/multiparameter-return-type/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/multiparameter-return-type/main.cx -------------------------------------------------------------------------------- /tests/integration/multiparameter-return-type/stdout.txt: -------------------------------------------------------------------------------- 1 | Good: hi 2 | -------------------------------------------------------------------------------- /tests/integration/mutable-array/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/mutable-array/main.cx -------------------------------------------------------------------------------- /tests/integration/mutable-array/stdout.txt: -------------------------------------------------------------------------------- 1 | foo 2 | bar 3 | -------------------------------------------------------------------------------- /tests/integration/name-functions-javascript-keywords/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/name-functions-javascript-keywords/main.cx -------------------------------------------------------------------------------- /tests/integration/name-functions-javascript-keywords/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/option-type-ident/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/option-type-ident/main.cx -------------------------------------------------------------------------------- /tests/integration/option-type-ident/stdout.txt: -------------------------------------------------------------------------------- 1 | some 2 | -------------------------------------------------------------------------------- /tests/integration/parameterized-type-alias/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/parameterized-type-alias/main.cx -------------------------------------------------------------------------------- /tests/integration/parameterized-type-alias/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/parametric-type-annotation/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/parametric-type-annotation/main.cx -------------------------------------------------------------------------------- /tests/integration/parametric-type-annotation/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/polymorphic-type-annotations-are-quantified-3/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/polymorphic-type-annotations-are-quantified-3/main.cx -------------------------------------------------------------------------------- /tests/integration/polymorphic-type-annotations-are-quantified-3/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/polymorphic-type-annotations-are-quantified-4/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/polymorphic-type-annotations-are-quantified-4/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/polymorphic-type-annotations-are-quantified-4/main.cx -------------------------------------------------------------------------------- /tests/integration/polymorphic-type-annotations-are-quantified/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/polymorphic-type-annotations-are-quantified/main.cx -------------------------------------------------------------------------------- /tests/integration/polymorphic-type-annotations-are-quantified/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/prelude-provides-option/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/prelude-provides-option/main.cx -------------------------------------------------------------------------------- /tests/integration/prelude-provides-option/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/quantify-user-types/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/quantify-user-types/main.cx -------------------------------------------------------------------------------- /tests/integration/quantify-user-types/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/records/annotation/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/annotation/main.cx -------------------------------------------------------------------------------- /tests/integration/records/annotation/stdout.txt: -------------------------------------------------------------------------------- 1 | Hoop 2 | -------------------------------------------------------------------------------- /tests/integration/records/errors/annotation-is-checked/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/records/errors/annotation-is-checked/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/errors/annotation-is-checked/main.cx -------------------------------------------------------------------------------- /tests/integration/records/errors/closed-and-quantified/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification -------------------------------------------------------------------------------- /tests/integration/records/errors/closed-and-quantified/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/errors/closed-and-quantified/main.cx -------------------------------------------------------------------------------- /tests/integration/records/errors/quantified-constraint-incompatible/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/records/errors/quantified-constraint-incompatible/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/errors/quantified-constraint-incompatible/main.cx -------------------------------------------------------------------------------- /tests/integration/records/errors/quantified-constraint-violation/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification -------------------------------------------------------------------------------- /tests/integration/records/errors/quantified-constraint-violation/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/errors/quantified-constraint-violation/main.cx -------------------------------------------------------------------------------- /tests/integration/records/errors/quantified-constraints/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/records/errors/quantified-constraints/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/errors/quantified-constraints/main.cx -------------------------------------------------------------------------------- /tests/integration/records/fields-immutable-by-default/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: record-mutability-unification 2 | 3 | -------------------------------------------------------------------------------- /tests/integration/records/fields-immutable-by-default/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/fields-immutable-by-default/main.cx -------------------------------------------------------------------------------- /tests/integration/records/inferred-field-accepts-mutable-or-immutable/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/inferred-field-accepts-mutable-or-immutable/main.cx -------------------------------------------------------------------------------- /tests/integration/records/inferred-field-accepts-mutable-or-immutable/stdout.txt: -------------------------------------------------------------------------------- 1 | 44 2 | 0 3 | -------------------------------------------------------------------------------- /tests/integration/records/mutable/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/mutable/main.cx -------------------------------------------------------------------------------- /tests/integration/records/mutable/stdout.txt: -------------------------------------------------------------------------------- 1 | 22 2 | -------------------------------------------------------------------------------- /tests/integration/records/optional-fields/jsoption/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/optional-fields/jsoption/main.cx -------------------------------------------------------------------------------- /tests/integration/records/optional-fields/jsoption/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | - 3 | 2 4 | present 5 | - 6 | -------------------------------------------------------------------------------- /tests/integration/records/optional-fields/option/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/optional-fields/option/main.cx -------------------------------------------------------------------------------- /tests/integration/records/optional-fields/option/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | - 3 | 2 4 | present 5 | - 6 | -------------------------------------------------------------------------------- /tests/integration/records/optional-fields/unification/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/optional-fields/unification/main.cx -------------------------------------------------------------------------------- /tests/integration/records/optional-fields/unification/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | none 3 | -------------------------------------------------------------------------------- /tests/integration/records/quantified-mutability/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/quantified-mutability/main.cx -------------------------------------------------------------------------------- /tests/integration/records/quantified-mutability/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | hi 3 | bye 4 | -------------------------------------------------------------------------------- /tests/integration/records/quantified/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/quantified/main.cx -------------------------------------------------------------------------------- /tests/integration/records/quantified/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/records/row-variables-are-checked/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: record-mutability-unification 2 | -------------------------------------------------------------------------------- /tests/integration/records/row-variables-are-checked/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/row-variables-are-checked/main.cx -------------------------------------------------------------------------------- /tests/integration/records/self-unification/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/self-unification/main.cx -------------------------------------------------------------------------------- /tests/integration/records/self-unification/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/records/type-parameter/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/records/type-parameter/main.cx -------------------------------------------------------------------------------- /tests/integration/records/type-parameter/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/recursive-data/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/recursive-data/main.cx -------------------------------------------------------------------------------- /tests/integration/recursive-data/stdout.txt: -------------------------------------------------------------------------------- 1 | 3 2 | -------------------------------------------------------------------------------- /tests/integration/recursive/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/recursive/main.cx -------------------------------------------------------------------------------- /tests/integration/recursive/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | -------------------------------------------------------------------------------- /tests/integration/return-type-parsing/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/return-type-parsing/main.cx -------------------------------------------------------------------------------- /tests/integration/return-type-parsing/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/return-unifies-with-anything/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/return-unifies-with-anything/main.cx -------------------------------------------------------------------------------- /tests/integration/return-unifies-with-anything/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/row-polymorphism-2/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/row-polymorphism-2/main.cx -------------------------------------------------------------------------------- /tests/integration/row-polymorphism-2/stdout.txt: -------------------------------------------------------------------------------- 1 | 44 2 | 11 3 | -------------------------------------------------------------------------------- /tests/integration/row-polymorphism/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/row-polymorphism/main.cx -------------------------------------------------------------------------------- /tests/integration/row-polymorphism/stdout.txt: -------------------------------------------------------------------------------- 1 | 0 2 | 77 3 | -------------------------------------------------------------------------------- /tests/integration/scope/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/scope/main.cx -------------------------------------------------------------------------------- /tests/integration/scope/stdout.txt: -------------------------------------------------------------------------------- 1 | 2 2 | -------------------------------------------------------------------------------- /tests/integration/string-methods/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/string-methods/main.cx -------------------------------------------------------------------------------- /tests/integration/string-methods/stdout.txt: -------------------------------------------------------------------------------- 1 | true 2 | false 3 | -------------------------------------------------------------------------------- /tests/integration/tdnr/inside-each/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tdnr/inside-each/main.cx -------------------------------------------------------------------------------- /tests/integration/tdnr/inside-each/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | 3 4 | -------------------------------------------------------------------------------- /tests/integration/tdnr/inside-for-loop/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tdnr/inside-for-loop/main.cx -------------------------------------------------------------------------------- /tests/integration/tdnr/inside-for-loop/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | 3 4 | -------------------------------------------------------------------------------- /tests/integration/tdnr/inside-this-module/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tdnr/inside-this-module/main.cx -------------------------------------------------------------------------------- /tests/integration/tdnr/inside-this-module/stdout.txt: -------------------------------------------------------------------------------- 1 | hello oop world 2 | -------------------------------------------------------------------------------- /tests/integration/tdnr/quantifies-function/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tdnr/quantifies-function/main.cx -------------------------------------------------------------------------------- /tests/integration/tdnr/quantifies-function/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | 3 4 | -------------------------------------------------------------------------------- /tests/integration/tdnr/type-qualified/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tdnr/type-qualified/main.cx -------------------------------------------------------------------------------- /tests/integration/tdnr/type-qualified/stdout.txt: -------------------------------------------------------------------------------- 1 | hello 2 | -------------------------------------------------------------------------------- /tests/integration/tdnr/with-arg-annotation/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tdnr/with-arg-annotation/main.cx -------------------------------------------------------------------------------- /tests/integration/tdnr/with-arg-annotation/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/top-level-function-call/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/top-level-function-call/main.cx -------------------------------------------------------------------------------- /tests/integration/top-level-function-call/stdout.txt: -------------------------------------------------------------------------------- 1 | hello 2 | world 3 | -------------------------------------------------------------------------------- /tests/integration/tostring/main.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | print(toString(5 as Number)) 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/tostring/stdout.txt: -------------------------------------------------------------------------------- 1 | 5 2 | -------------------------------------------------------------------------------- /tests/integration/traits/ambiguous-trait-name/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/ambiguous-trait-name/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/ambiguous-trait-name/one.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/ambiguous-trait-name/one.cx -------------------------------------------------------------------------------- /tests/integration/traits/ambiguous-trait-name/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/ambiguous-trait-name/stdout.txt -------------------------------------------------------------------------------- /tests/integration/traits/ambiguous-trait-name/two.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/ambiguous-trait-name/two.cx -------------------------------------------------------------------------------- /tests/integration/traits/basic/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/basic/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/basic/stdout.txt: -------------------------------------------------------------------------------- 1 | 15 2 | -------------------------------------------------------------------------------- /tests/integration/traits/constrained-instances-2/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/constrained-instances-2/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/constrained-instances-2/stdout.txt: -------------------------------------------------------------------------------- 1 | hello 2 | -------------------------------------------------------------------------------- /tests/integration/traits/constrained-instances/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/constrained-instances/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/constrained-instances/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/constrained-instances/stdout.txt -------------------------------------------------------------------------------- /tests/integration/traits/defaults/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/defaults/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/defaults/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | Default 3 | -------------------------------------------------------------------------------- /tests/integration/traits/defaults_method_syntax/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/defaults_method_syntax/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/defaults_method_syntax/stdout.txt: -------------------------------------------------------------------------------- 1 | 10 2 | Default 3 | -------------------------------------------------------------------------------- /tests/integration/traits/defaults_must_have_correct_type/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/traits/defaults_must_have_correct_type/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/defaults_must_have_correct_type/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/duplicate-impl-method/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: duplicate-symbol 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/duplicate-impl-method/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/duplicate-impl-method/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/duplicate-method/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: duplicate-symbol 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/duplicate-method/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/duplicate-method/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/extra-method/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unexpected-impl-method 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/extra-method/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/extra-method/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/impl-type/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/impl-type/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/impl-type/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/incomplete-impl/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: incomplete-impl 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/incomplete-impl/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/incomplete-impl/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/no-type-variables/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: type-application-mismatch 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/no-type-variables/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/no-type-variables/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/quant-trait/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: no-trait-on-type 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/quant-trait/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/quant-trait/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/errors/too-many-type-variables/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: illegal-type-application 2 | -------------------------------------------------------------------------------- /tests/integration/traits/errors/too-many-type-variables/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/errors/too-many-type-variables/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/function-impl/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/function-impl/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/function-impl/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/traits/impl-not-available-before-definition/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: no-trait-on-type 2 | -------------------------------------------------------------------------------- /tests/integration/traits/impl-not-available-before-definition/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/impl-not-available-before-definition/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/impl-tdnr/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/impl-tdnr/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/impl-tdnr/stdout.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/impl-tdnr/stdout.txt -------------------------------------------------------------------------------- /tests/integration/traits/imported-trait-name/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/imported-trait-name/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/imported-trait-name/one.cx: -------------------------------------------------------------------------------- 1 | export trait One { 2 | go(self): () 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/traits/imported-trait-name/stdout.txt: -------------------------------------------------------------------------------- 1 | one: one 2 | two: two 3 | -------------------------------------------------------------------------------- /tests/integration/traits/imported-trait-name/two.cx: -------------------------------------------------------------------------------- 1 | export trait Two { 2 | go(self): () 3 | } 4 | -------------------------------------------------------------------------------- /tests/integration/traits/let/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/let/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/let/stdout.txt: -------------------------------------------------------------------------------- 1 | 15 2 | -------------------------------------------------------------------------------- /tests/integration/traits/polymorphic-ambiguity/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: ambiguous-polymorphism 2 | -------------------------------------------------------------------------------- /tests/integration/traits/polymorphic-ambiguity/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/polymorphic-ambiguity/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/polymorphic-expressions/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/polymorphic-expressions/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/polymorphic-expressions/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | 3 4 | 4 5 | 5 6 | -------------------------------------------------------------------------------- /tests/integration/traits/quant/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/quant/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/quant/stdout.txt: -------------------------------------------------------------------------------- 1 | 15 2 | -------------------------------------------------------------------------------- /tests/integration/traits/rebound-trait-values/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/rebound-trait-values/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/rebound-trait-values/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | -------------------------------------------------------------------------------- /tests/integration/traits/record-constraints/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/record-constraints/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/record-constraints/stdout.txt: -------------------------------------------------------------------------------- 1 | x 2 | String 3 | y 4 | Number 5 | z 6 | () 7 | -------------------------------------------------------------------------------- /tests/integration/traits/record-field-does-not-unify/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/traits/record-field-does-not-unify/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/record-field-does-not-unify/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/record-field-qvar/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/record-field-qvar/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/record-field-qvar/stdout.txt: -------------------------------------------------------------------------------- 1 | x 2 | hello 3 | y 4 | world 5 | a 6 | 10 7 | b 8 | 20 9 | -------------------------------------------------------------------------------- /tests/integration/traits/record-field-result-does-not-unify/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/traits/record-field-result-does-not-unify/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/record-field-result-does-not-unify/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/record-field-traits/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/record-field-traits/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/record-field-traits/stdout.txt: -------------------------------------------------------------------------------- 1 | x 2 | Number 3 | y 4 | String 5 | z 6 | Array 7 | -------------------------------------------------------------------------------- /tests/integration/traits/record-fields/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/record-fields/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/record-fields/stdout.txt: -------------------------------------------------------------------------------- 1 | x 2 | 10 3 | y 4 | 20 5 | z 6 | hi 7 | -------------------------------------------------------------------------------- /tests/integration/traits/records/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/records/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/records/stdout.txt: -------------------------------------------------------------------------------- 1 | number 2 | string 3 | record 4 | -------------------------------------------------------------------------------- /tests/integration/traits/sugar/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/sugar/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/sugar/stdout.txt: -------------------------------------------------------------------------------- 1 | true 2 | false 3 | -------------------------------------------------------------------------------- /tests/integration/traits/syntax/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/syntax/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/syntax/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/traits/value-elements/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/traits/value-elements/main.cx -------------------------------------------------------------------------------- /tests/integration/traits/value-elements/stdout.txt: -------------------------------------------------------------------------------- 1 | 3 2 | -------------------------------------------------------------------------------- /tests/integration/tuples/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/tuples/main.cx -------------------------------------------------------------------------------- /tests/integration/tuples/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 2 3 | -------------------------------------------------------------------------------- /tests/integration/type-alias/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-alias/main.cx -------------------------------------------------------------------------------- /tests/integration/type-alias/stdout.txt: -------------------------------------------------------------------------------- 1 | 59 2 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/dict-record/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/dict-record/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/dict-record/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/function-decls/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/function-decls/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/function-decls/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/function-ident/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/function-ident/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/function-ident/stdout.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/quantified-record/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/quantified-record/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/quantified-record/stdout.txt: -------------------------------------------------------------------------------- 1 | Hello 2 | World 3 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/trait/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: no-trait-on-type 2 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/trait/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/trait/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/type-param-alias/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/type-param-alias/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/type-param-alias/stdout.txt: -------------------------------------------------------------------------------- 1 | prefix world 2 | -------------------------------------------------------------------------------- /tests/integration/type-annotations/wildcard/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/type-annotations/wildcard/main.cx -------------------------------------------------------------------------------- /tests/integration/type-annotations/wildcard/stdout.txt: -------------------------------------------------------------------------------- 1 | hello 2 | -------------------------------------------------------------------------------- /tests/integration/unary-operators/negative-literal/main.cx: -------------------------------------------------------------------------------- 1 | fun main() { 2 | print(-10 as Number) 3 | } -------------------------------------------------------------------------------- /tests/integration/unary-operators/negative-literal/stdout.txt: -------------------------------------------------------------------------------- 1 | -10 2 | -------------------------------------------------------------------------------- /tests/integration/unary-operators/negative-operator/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/unary-operators/negative-operator/main.cx -------------------------------------------------------------------------------- /tests/integration/unary-operators/negative-operator/stdout.txt: -------------------------------------------------------------------------------- 1 | -5 2 | -------------------------------------------------------------------------------- /tests/integration/unify/number-with-quantified/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/unify/number-with-quantified/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/unify/number-with-quantified/main.cx -------------------------------------------------------------------------------- /tests/integration/unsafe-coerce/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/unsafe-coerce/main.cx -------------------------------------------------------------------------------- /tests/integration/unsafe-coerce/stdout.txt: -------------------------------------------------------------------------------- 1 | 5ohai 2 | -------------------------------------------------------------------------------- /tests/integration/unsafe-js/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/unsafe-js/main.cx -------------------------------------------------------------------------------- /tests/integration/unsafe-js/stdout.txt: -------------------------------------------------------------------------------- 1 | hoop 2 | -------------------------------------------------------------------------------- /tests/integration/weak-polymorphism/array/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/weak-polymorphism/array/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/weak-polymorphism/array/main.cx -------------------------------------------------------------------------------- /tests/integration/weak-polymorphism/letmut/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/weak-polymorphism/letmut/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/weak-polymorphism/letmut/main.cx -------------------------------------------------------------------------------- /tests/integration/weak-polymorphism/record/error.yaml: -------------------------------------------------------------------------------- 1 | type-error-name: unification 2 | -------------------------------------------------------------------------------- /tests/integration/weak-polymorphism/record/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/weak-polymorphism/record/main.cx -------------------------------------------------------------------------------- /tests/integration/while-loops/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/while-loops/main.cx -------------------------------------------------------------------------------- /tests/integration/while-loops/stdout.txt: -------------------------------------------------------------------------------- 1 | 1 2 | 1 3 | 2 4 | 3 5 | 5 6 | 8 7 | 13 8 | 21 9 | 34 10 | -------------------------------------------------------------------------------- /tests/integration/wildcard-function-arguments/main.cx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cruxlang/crux/HEAD/tests/integration/wildcard-function-arguments/main.cx -------------------------------------------------------------------------------- /tests/integration/wildcard-function-arguments/stdout.txt: -------------------------------------------------------------------------------- 1 | inner 2 | --------------------------------------------------------------------------------