purescript

A strongly-typed language that compiles to JavaScript

OTHER License

Downloads
10.2K
Stars
8.4K
Committers
200

Bot releases are visible (Hide)

purescript -

Published by paf31 over 5 years ago

Enhancements

  • Add better positions for UnknownName errors for types/kinds (#3515, @colinwahl)

    Previously an UnknownName error (arising from e.g. referring to a non-existent type, or a type which you forgot to import) would have a span covering the whole type annotation. Now, the error span only covers the relevant part of the type.

  • Boost performance of purs docs by simplifying re-export handling (#3534, @hdgarrood)

Bug fixes

  • Fix applicative do notation breaking API documentation generation with purs docs (#3414, @hdgarrood)
  • Fix the REPL browser backend (#3387, @dariooddenino)

Other

  • Make the license generator a proper stack script (@kRITZCREEK)
  • Include the module from which something was imported for re-exports in externs files (@hdgarrood)
  • Add AppVeyor build status to README.md (@hdgarrood)
purescript - v0.12.2

Published by garyb almost 6 years ago

New features

  • Named type wildcards (#3500, @natefaubion)

    It's now possible to use ?hole style syntax in type signatures where you want the compiler to tell you the missing type. This was previously possible by using _ in a type signature, but now _ can be used without raising a warning, as long as it does not appear in a top level declaration.

Enhancements

  • Improve error message for missing node.js in the repl (#3456, @justinwoo)
  • Add Boolean kind to Prim.Boolean (#3389, @justinwoo)
  • Link to documentation repo as docs for non-Prim built-in types/kinds (#3460, @JordanMartinez)
  • PSCi: Support multiple command types in paste-mode (#3471, @LiamGoodacre)
  • Add row:column printing for source positions in error messages (#3473, @justinwoo)
  • Add :print directive for customizable repl printing (#3478, @hdgarrood)
  • Implement qualified do (#3373, @pkamenarsky)
  • Add better source positions to kind errors (#3495, @natefaubion)

Fixes

  • Remove references to previous kinds * and ! (#3458, @LiamGoodacre)
  • Fix linting of unused type variables (#3464, @LiamGoodacre)
  • Avoid dropping super class dicts for the same class (#3461, @LiamGoodacre)
  • Fix issue where Partial can foil TCO optimizations (#3218, @matthewleon)
  • Fix quoting of record labels in error messages (#3480, @hdgarrood)
  • Prevent invalid JS being generated from awkward record labels (#3486, @hdgarrood)
  • Fix unnecessary quoting of reserved names when used as labels (#3487, @hdgarrood)
  • Fix source spans for binding groups (#3462, @LiamGoodacre)
  • Fix kind error for recursive data type (#3511, @natefaubion)

Other (internals)

  • Add annotations to Type and Kind (#3484, @natefaubion)
  • Use handwritten JSON instances for Type/Kind (#3496, @natefaubion)
  • Remove pretty print constructors from Type (#3498, @natefaubion)
  • Add JSON compatibility tests (#3497, @hdgarrood)
  • Remove the concept of the 'current module' in Docs (#3506, @hdgarrood)
purescript - v0.12.1

Published by garyb almost 6 years ago

Enhancements

  • Print types of missing typeclass members (#3398, @fehrenbach)
  • Added Prim.TypeError.QuoteLabel for pretty printing labels in custom type errors (#3436, @dariooddenino)
  • purs ide accepts codegen targets for the rebuild command (#3449, @kRITZCREEK)

Fixes

  • Fixes errors spans for CannotFindDerivingType (#3425, @kRITZCREEK)
  • Fixes a traversal bug where ObjectNestedUpdate was surviving desugaring (#3388, @natefaubion)
  • Fixes type operators reexports (#3410, @natefaubion)
  • Fixes ST magic-do and inlining (#3444, @natefaubion)
  • Fixes missing span information when using do-syntax without importing bind or discard (#3418, @natefaubion)
  • Fixes missing span information when shadowing an open import with a module definition (#3417, @natefaubion)
  • Fixes stale :browse environment after :reload (#3001, @rndnoise)

Other

  • Fix test-support dependency versions and update psci browse test (#3374, @LiamGoodacre)
  • Changes to build with GHC 8.4.3 (#3372, @kRITZCREEK)
  • Set --haddock flag based on BUILD_TYPE (#3409, @justinwoo)
  • Use microlens-platform instead of lens (#3400, @joneshf)
  • Avoid Data.ByteString.Lazy.toStrict (#3433, @coot)
  • Add ffiCodegen to MakeActions (#3434, @coot)
  • Add nix config to stack.yaml (#3435, @f-f)
purescript - v0.12.0

Published by garyb over 6 years ago

Breaking changes

  • Added applicative-do notation; ado is now a keyword. An full explanation of the behaviour and usage of ado is available in a comment on the issue. (#2889, @rightfold)
  • Removed wrapper scripts for the old binary names (psc, psci, etc.) (#2993, @hdgarrood)
  • Removed compiler support for deriving purescript-generics. purescript-generics-rep is still supported. (#3007, @paf31)
  • Instances with just one method now require the method to be indented (bug fix, but potentially breaking) (#2947, @quesebifurcan)
  • Overlapping instances are now an error rather than a warning, but can be resolved with the new instance chain groups feature (#2315, @LiamGoodacre)
  • Reworked the CoreFn json representation. This change enables use of the Zephyr tree shaking tool for PureScript. (#3049, #3342, @coot)
  • It is no longer possible to export a type class that has superclasses that are not also exported (bug fix, but potentially breaking) (#3132, @parsonsmatt)
  • Eq and Ord deriving will now rely on Eq1 and Ord1 constraints as necessary where sometimes previously Eq (f _) would be required. Eq1 and Ord1 instances can also be derived. (#3207, @garyb)
  • Some Prim type classes have been renamed/moved, so will require explicit importing (#3176, @parsonsmatt):
    • RowCons is now Prim.Row.Cons
    • Union is now Prim.Row.Union
    • Fail is now Prim.TypeError.Fail
    • Warn is now Prim.TypeError.Warn
  • Users can no longer specify modules under the Prim namespace (#3291, @parsonsmatt)
  • TypeConcat and TypeString have been replaced because they were in kind Symbol but weren't literals. The Prim.TypeError.Doc kind and related constructors (Text, Quote, Beside, Above) have been added in their place. The Fail and Warn type classes now accept a Doc instead of a Symbol.
    (#3134, @LiamGoodacre)
  • In simple cases instance overlaps are now checked at declaration time rather than being deferred until an attempt is made to use them. (#3129, @LiamGoodacre)
  • Chaining non-associative or mixed associativity operators of the same precedence is no longer allowed (#3315, @garyb)
  • The --dump-corefn and --source-maps arguments to purs compile have been removed. There is now a --codegen argument that allows the specific codegen targets to be specified - for example, --codegen corefn will not produce JS files, --codgen js,corefn will produce both. If the sourcemaps target is used js will be implied, so there's no difference between --codegen js,sourcemaps and --codegen sourcemaps). If no targets are specified the default is js. (#3196, @garyb, @gabejohnson)
  • Exported types that use foreign kinds now require the foreign kinds to be exported too (bug fix, but potentially breaking) (#3331, @garyb)
  • The pursuit commands were removed from purs ide due to lack of use and editor tooling implementing the features instead (#3355, @kRITZCREEK)

Enhancements

  • Added Cons compiler-solved type class for Symbol (#3054, @kcsongor)
  • The Append compiler-solved type class for Symbol can now be run in reverse (#3025, @paf31)
  • Find Usages for values and constructors in purs ide (#3206, @kRITZCREEK)
  • purs ide treats hiding imports the same as open imports when sorting (#3069, @kRITZCREEK)
  • Added inlining for fully saturated usages of runEffFn/mkEffFn (#3026, @nwolverson)
  • Improved explanation of UnusableDeclaration error (#3088, #3304, @i-am-tom)
  • Improved rendering of comments in generated JavaScript by removing additional newlines (#3096, @brandonhamilton)
  • Instance chain support. (#2315, @LiamGoodacre)

    We can now express an explicit ordering on instances that would previously have been overlapping.
    For example we could now write an IsEqual type class to compute if two types are equal or apart:

    class IsEqual (l :: Type) (r :: Type) (o :: Boolean) | l r -> o
    instance isEqualRefl :: IsEqual x x True
    else instance isEqualContra :: IsEqual l r False
    

    Note the else keyword that links the two instances together.
    The isEqualContra will only be up for selection once the compiler knows it couldn't possible select isEqualRefl - i.e that l and r are definitely not equal.

  • Improved orphan instance error to include locations where the instance would be valid (#3106, @i-am-tom)
  • Added an explicit error for better explanation of duplicate type class or instance declarations (#3093, @LiamGoodacre)
  • purs ide now provide documentation comments (#2349, @nwolverson)
  • Clarified meaning of duplicate labels in a Record row (#3143, @paf31)
  • Explicit import suggestions consistently use (..) for constructors now (#3142, @nwolverson)
  • Improved tab completion in purs repl (#3227, @rndnoise)
  • Large compiler perfomance improvement in some cases by skipping source spans in Eq, Ord for binders (#3265, @bitemyapp)
  • Added support for error/warning messages to carry multiple source spans (#3255, @garyb)
  • Improved tab completion in purs repl when parens and brackets are involved (#3236, @rndnoise)
  • Improved completion in purs repl after :kind and :type (#3237, @rndnoise)
  • Added the "magic do" optimisation for the new simplified Effect type (Control.Monad.Eff is still supported) (#3289, @kRITZCREEK, #3301, @garyb)
  • Improvide build startup times when resuming a build with incremental results (#3270, @kRITZCREEK)
  • Added compiler-solved Prim.Row.Nub type class (#3293, @natefaubion)
  • Improved docs for Prim.Row.Cons and Prim.Row.Union (#3292, @vladciobanu)
  • Functor can now be derived when quantifiers are used in constructors (#3232, @i-am-tom)
  • purs repl will now complete types after :: (#3239, @rndnoise)
  • Added compiler-solved Prim.Row.Lacks type class (#3305, @natefaubion)
  • Added current output path to missing output error message from purs ide (#3311, @rgrinberg)
  • Improved parser error messages for .purs-repl (#3248, @rndnoise)
  • require in generated JavaScript now includes full index.js file paths (#2621, @chexxor)
  • Added more compiler-solved type classes and supporting types and kinds to Prim:
    • Prim.Ordering module with kind Ordering, type LT, type EQ, type GT
    • Prim.RowList module with class RowToList, kind RowList, type Nil, type Cons
    • Prim.Symbol module with class Compare, class Append, class Cons
      (#3312, @LiamGoodacre, @kRITZCREEK)
  • Generated code for closed records now explicitly reconstructs the record rather than looping (#1493, @fehrenbach, blog post with more details)
  • Enhanced purs --help message to include hint about using --help with commands (#3344, @hdgarrood)
  • IncorrectConstructorArity error message now includes a hint of how many arguments are expected for the constructor (#3353, @joneshf)
  • purs ide now uses absolute locations for file paths for better experience in some editors (#3363, @kRITZCREEK)

Bug fixes

  • Fixed a bug with names cause by Prim always being imported unqualified (#2197, @LightAndLight)
  • Fixed overlapping instances error message to reflect its new status as an error (#3084, @drets)
  • Added source position to TypeClassDeclaration errors (#3109, @b123400)
  • Fixed entailment issues with skolems and matches in the typechecker (#3121, @LiamGoodacre)
  • Fixed multiple parentheses around a type causing a crash (#3085, @MonoidMusician)
  • Fixed purs ide inserting conflicting imports for types (#3131, @nwolverson)
  • Fixed constraints being inferred differently for lambda expressions compared with equational declarations (#3125, @LiamGoodacre)
  • Updated glob handling to prevent excessive memory usage (#3055, @hdgarrood)
  • Added position information to warnings in type declarations (#3174, @b123400)
  • Fixed documentation generated for Pursuit rendering functional dependency variables as identifier links (#3180, @houli)
  • Naming a function argument __unused no longer breaks codegen (#3187, @matthewleon)
  • Added position information to ShadowedName warning (#3213, @garyb)
  • Added position information to UnusedTypeVar warning (#3214, @garyb)
  • Added position information to MissingClassMember, ExtraneousClassMember, ExpectedWildcard errors (#3216, @garyb)
  • Added position information to ExportConflict errors (#3217, @garyb)
  • Fixed ctags and etags generation when explicit exports are involved (#3204, @matthewleon)
  • Added position information to ScopeShadowing warning (#3219, @garyb)
  • Added position information for various FFI related errors and warnings (#3276, @garyb)
  • Added all available positions to CycleInModule and DuplicateModule errors (#3273, @garyb)
  • Added position information for IntOutOfRange errors (#3277, @garyb, @kRITZCREEK)
  • Warnings are now raised when a module re-exports a qualified module with implicit import (#2726, @garyb)
  • purs repl now shows results for :browse Prim (#2672, @rndnoise)
  • Added position information to ErrorParsingFFIModule (#3307, @nwolverson)
  • Added position information for ScopeConflict cause by exports (#3318, @garyb)
  • Added position information to errors that occur in binding groups and data binding groups (#3275, @garyb)
  • Fixed a scoping issue when resolving operators (#2803, @kRITZCREEK, @LightAndLight)
  • Type synonyms are now desugared earlier when newtype deriving (#3325, @LiamGoodacre)
  • Fixed subgoals of compiler-solved type classes being ignored (#3333, @LiamGoodacre)
  • Added position information to type operator associativity errors (#3337, @garyb)
  • Updated description of purs docs command (#3343, @hdgarrood)
  • Fixed purs docs issue with re-exporting from Prim submodules (#3347, @hdgarrood)
  • Enabled purs ide imports for Prim submodules (#3352, @kRITZCREEK)
  • Fixed purs bundle failing to bundle in the 0.12-rc1 (#3359, @garyb)
  • Enabled :browse for Prim submodules in purs repl (#3364, @kRITZCREEK)

Other

  • Updated installation information to include details about prebuild binaries (#3167, @MiracleBlue)
  • Test suite now prints output when failing cases are encountered (#3181, @parsonsmatt)
  • Updated test suite to use tasty (#2848, @kRITZCREEK)
  • Improved performance of repl test suite (#3234, @rndnoise)
  • Refactored let pattern desugaring to be less brittle (#3268, @kRITZCREEK)
  • Added makefile with common tasks for contributors (#3266, @bitemyapp)
  • Added ghcid and testing commands to makefile (#3290, @parsonsmatt)
  • Removed old unused MultipleFFIModules error (#3308, @nwolverson)
  • mod and div for Int are no longer inlined as their definition has changed in a way that makes their implementation more complicated - purescript/purescript-prelude#161 (#3309, @garyb)
  • The test suite now checks warnings and errors have position information (#3211, @garyb)
  • The AST was updated to be able to differentiate between let and where clauses (#3317, @joneshf)
  • Support for an optimization pass on CoreFn was added (#3319, @matthewleon)
  • Clarified note in the purs ide docs about the behaviour of --editor-mode (#3350, @chexxor)
  • Updated bundle/install docs for 0.12 (#3357, @hdgarrood)
  • Removed old readme for psc-bundle (a leftover from before the unified purs binary) (#3356, @Cmdv)
purescript - v0.12.0-rc1

Published by garyb over 6 years ago

Breaking changes

  • Added applicative-do notation; ado is now a keyword. An full explanation of the behaviour and usage of ado is available in a comment on the issue. (#2889, @rightfold)
  • Removed wrapper scripts for the old binary names (psc, psci, etc.) (#2993, @hdgarrood)
  • Removed compiler support for deriving purescript-generics. purescript-generics-rep is still supported. (#3007, @paf31)
  • Instances with just one method now require the method to be indented (bug fix, but potentially breaking) (#2947, @quesebifurcan)
  • Overlapping instances are now an error rather than a warning, but can be resolved with the new instance chain groups feature (#2315, @LiamGoodacre)
  • Reworked the CoreFn json representation (#3049, @coot)
  • It is no longer possible to export a type class that has superclasses that are not also exported (bug fix, but potentially breaking) (#3132, @parsonsmatt)
  • Eq and Ord deriving will now rely on Eq1 and Ord1 constraints as necessary where sometimes previously Eq (f _) would be required. Eq1 and Ord1 instances can also be derived. (#3207, @garyb)
  • Some Prim type classes have been renamed/moved, so will require explicit importing (#3176, @parsonsmatt):
    • RowCons is now Prim.Row.Cons
    • Union is now Prim.Row.Union
    • Fail is now Prim.TypeError.Fail
    • Warn is now Prim.TypeError.Warn
  • Users can no longer specify modules under the Prim namespace (#3291, @parsonsmatt)
  • TypeConcat and TypeString have been replaced because they were in kind Symbol but weren't literals. The Prim.TypeErrer.Doc kind and related constructors (Text, Quote, Beside, Above) have been added in their place. The Fail and Warn type classes now accept a Doc instead of a Symbol.
    (#3134, @LiamGoodacre)
  • In simple cases instance overlaps are now checked at declaration time rather than being deferred until an attempt is made to use them. (#3129, @LiamGoodacre)
  • Chaining non-associative or mixed associativity operators of the same precedence is no longer allowed (#3315, @garyb)
  • The --dump-corefn and --source-maps arguments to purs compile have been removed. There is now a --codegen argument that allows the specific codegen targets to be specified - for example, --codegen corefn will not produce JS files, --codgen js,corefn will produce both. If the sourcemaps target is used js will be implied, so there's no difference between --codegen js,sourcemaps and --codegen sourcemaps). If no targets are specified the default is js. (#3196, @garyb, @gabejohnson)
  • Exported types that use foreign kinds now require the foreign kinds to be exported too (bug fix, but potentially breaking) (#3331, @garyb)

Enhancements

  • Added Cons compiler-solved type class for Symbol (#3054, @kcsongor)
  • The Append compiler-solved type class for Symbol can now be run in reverse (#3025, @paf31)
  • Find Usages for values and constructors in purs ide (#3206, @kRITZCREEK)
  • purs ide treats hiding imports the same as open imports when sorting (#3069, @kRITZCREEK)
  • Added inlining for fully saturated usages of runEffFn/mkEffFn (#3026, @nwolverson)
  • Improved explanation of UnusableDeclaration error (#3088, #3304, @i-am-tom)
  • Improved rendering of comments in generated JavaScript by removing additional newlines (#3096, @brandonhamilton)
  • Instance chain support. (#2315, @LiamGoodacre)

    We can now express an explicit ordering on instances that would previously have been overlapping.
    For example we could now write an IsEqual type class to compute if two types are equal or apart:

    class IsEqual (l :: Type) (r :: Type) (o :: Boolean) | l r -> o
    instance isEqualRefl :: IsEqual x x True
    else instance isEqualContra :: IsEqual l r False
    

    Note the else keyword that links the two instances together.
    The isEqualContra will only be up for selection once the compiler knows it couldn't possible select isEqualRefl - i.e that l and r are definitely not equal.

  • Improved orphan instance error to include locations where the instance would be valid (#3106, @i-am-tom)
  • Added an explicit error for better explanation of duplicate type class or instance declarations (#3093, @LiamGoodacre)
  • purs ide now provide documentation comments (#2349, @nwolverson)
  • Clarified meaning of duplicate labels in a Record row (#3143, @paf31)
  • Explicit import suggestions consistently use (..) for constructors now (#3142, @nwolverson)
  • Improved tab completion in purs repl (#3227, @rndnoise)
  • Large compiler perfomance improvement in some cases by skipping source spans in Eq, Ord for binders (#3265, @bitemyapp)
  • Added support for error/warning messages to carry multiple source spans (#3255, @garyb)
  • Improved tab completion in purs repl when parens and brackets are involved (#3236, @rndnoise)
  • Improved completion in purs repl after :kind and :type (#3237, @rndnoise)
  • Added the "magic do" optimisation for the new simplified Effect type (Control.Monad.Eff is still supported) (#3289, @kRITZCREEK, #3301, @garyb)
  • Improvide build startup times when resuming a build with incremental results (#3270, @kRITZCREEK)
  • Added compiler-solved Prim.Row.Nub type class (#3293, @natefaubion)
  • Improved docs for Prim.Row.Cons and Prim.Row.Union (#3292, @vladciobanu)
  • Functor can now be derived when quantifiers are used in constructors (#3232, @i-am-tom)
  • purs repl will now complete types after :: (#3239, @rndnoise)
  • Added compiler-solved Prim.Row.Lacks type class (#3305, @natefaubion)
  • Added current output path to missing output error message from purs ide (#3311, @rgrinberg)
  • Improved parser error messages for .purs-repl (#3248, @rndnoise)
  • require in generated JavaScript now includes full index.js file paths (#2621, @chexxor)
  • Added more compiler-solved type classes and supporting types and kinds to Prim:
    • Prim.Ordering module with kind Ordering, type LT, type EQ, type GT
    • Prim.RowList module with class RowToList, kind RowList, type Nil, type Cons
    • Prim.Symbol module with class Compare, class Append, class Cons
      (#3312, @LiamGoodacre, @kRITZCREEK)
  • Generated code for closed records now explicitly reconstructs the record rather than looping (#1493, @fehrenbach, blog post with more details)

Bug fixes

  • Fixed a bug with names cause by Prim always being imported unqualified (#2197, @LightAndLight)
  • Fixed overlapping instances error message to reflect its new status as an error (#3084, @drets)
  • Added source position to TypeClassDeclaration errors (#3109, @b123400)
  • Fixed entailment issues with skolems and matches in the typechecker (#3121, @LiamGoodacre)
  • Fixed multiple parentheses around a type causing a crash (#3085, @MonoidMusician)
  • Fixed purs ide inserting conflicting imports for types (#3131, @nwolverson)
  • Fixed constraints being inferred differently for lambda expressions compared with equational declarations (#3125, @LiamGoodacre)
  • Updated glob handling to prevent excessive memory usage (#3055, @hdgarrood)
  • Added position information to warnings in type declarations (#3174, @b123400)
  • Fixed documentation generated for Pursuit rendering functional dependency variables as identifier links (#3180, @houli)
  • Naming a function argument __unused no longer breaks codegen (#3187, @matthewleon)
  • Added position information to ShadowedName warning (#3213, @garyb)
  • Added position information to UnusedTypeVar warning (#3214, @garyb)
  • Added position information to MissingClassMember, ExtraneousClassMember, ExpectedWildcard errors (#3216, @garyb)
  • Added position information to ExportConflict errors (#3217, @garyb)
  • Fixed ctags and etags generation when explicit exports are involved (#3204, @matthewleon)
  • Added position information to ScopeShadowing warning (#3219, @garyb)
  • Added position information for various FFI related errors and warnings (#3276, @garyb)
  • Added all available positions to CycleInModule and DuplicateModule errors (#3273, @garyb)
  • Added position information for IntOutOfRange errors (#3277, @garyb, @kRITZCREEK)
  • Warnings are now raised when a module re-exports a qualified module with implicit import (#2726, @garyb)
  • purs repl now shows results for :browse Prim (#2672, @rndnoise)
  • Added position information to ErrorParsingFFIModule (#3307, @nwolverson)
  • Added position information for ScopeConflict cause by exports (#3318, @garyb)
  • Added position information to errors that occur in binding groups and data binding groups (#3275, @garyb)
  • Fixed a scoping issue when resolving operators (#2803, @kRITZCREEK, @LightAndLight)
  • Type synonyms are now desugared earlier when newtype deriving (#3325, @LiamGoodacre)
  • Fixed subgoals of compiler-solved type classes being ignored (#3333, @LiamGoodacre)
  • Added position information to type operator associativity errors (#3337, @garyb)

Other

  • Updated installation information to include details about prebuild binaries (#3167, @MiracleBlue)
  • Test suite now prints output when failing cases are encountered (#3181, @parsonsmatt)
  • Updated test suite to use tasty (#2848, @kRITZCREEK)
  • Improved performance of repl test suite (#3234, @rndnoise)
  • Refactored let pattern desugaring to be less brittle (#3268, @kRITZCREEK)
  • Added makefile with common tasks for contributors (#3266, @bitemyapp)
  • Added ghcid and testing commands to makefile (#3290, @parsonsmatt)
  • Removed old unused MultipleFFIModules error (#3308, @nwolverson)
  • mod and div for Int are no longer inlined as their definition has changed in a way that makes their implementation more complicated - purescript/purescript-prelude#161 (#3309, @garyb)
  • The test suite now checks warnings and errors have position information (#3211, @garyb)
  • The AST was updated to be able to differentiate between let and where clauses (#3317, @joneshf)
  • Support for an optimization pass on CoreFn was added (#3319, @matthewleon)
purescript - v0.11.7

Published by paf31 almost 7 years ago

Enhancements

  • Add position to type class declaration errors (@b123400)
  • Add valid location list to orphan instance errors (@i-am-tom)
  • Expand error message for UnusableDeclaration (#3088, @i-am-tom)
  • Inline Unsafe.Coerce.unsafeCoerce (@coot)

Bug Fixes

  • Correctly quote uppercased field labels in errors (@Thimoteus)
  • purs ide inserts conflicting imports for types (#3131, @nwolverson)
  • Instantiate abstraction body during inference to fix a type checking bug (@LiamGoodacre)
  • Fix a bug related to the desugaring of nested parentheses (@MonoidMusician)
  • Fix a loop in the kind checker (@paf31)
  • Fix a bug in type operator precedence parsing (@paf31)
  • Eliminate some redundant whitespace in the generated JS output (@matthewleon)
  • Only add newline before initial group of comment lines during code generation (@brandonhamilton)
  • Treat kinds as used in import warnings (@nwolverson)

purs ide

  • Add an "editor mode" (@kRITZCREEK)

    When the editor-mode flag is specified at startup the server will not start afile watcher process any more. Instead it only reloads after successful rebuild commands. This is a lot less fragile than relying on the file system APIs, but will mean that a manual load needs to be triggered after builds that didn't go through purs ide.

  • purs ide now groups hiding imports with implicit ones (@kRITZCREEK)

  • Return documentation comments in purs ide completions (@nwolverson)

  • Add an actualFile parameter to the rebuild command (@kRITZCREEK)

  • Add qualified explicit import (@nwolverson)

  • Fixed case-splitting on local non-exported datatypes (@LightAndLight)

  • Make the filters parameter in the type command optional (@b123400)

purs docs

  • Embed CSS for HTML docs (@hdgarrood)
  • Fix source links for re-exports (@felixSchl)
  • Use order given in export list in generated docs (@hdgarrood)
  • Prevent browser from treating the title and source link as one word (@Rufflewind)
  • Fix fragment links to type constructors in HTML (@hdgarrood)

purs repl

  • Add :complete directive to purs repl to support completion in more editors (@actionshrimp)

Other

  • Add docs for duplicate labels in record types (@paf31)
  • Adds a document for the design of purs ide. (@kRITZCREEK)
  • Update PROTOCOL.md docs for purs ide (@BjornMelgaard)
  • Upgrade to GHC version 8.2 (@kRITZCREEK)
  • Allow blaze-html-0.9 (@felixonmars)
  • Bump Glob dependency (@mjhoy)
  • Use Hspec in TestDocs (@hdgarrood)
  • Fix AppVeyor deployment (#2774) (@hdgarrood)
  • Various type safety improvements to the AST (@kRITZCREEK)
  • Remove some references to old executables (@hdgarrood)
  • Update the installation documentation (@hdgarrood)
  • Update test dependencies (@hdgarrood)
  • Only build master and versioned tags in AppVeyor (@hdgarrood)
purescript - v0.11.6

Published by paf31 over 7 years ago

New Features

RowToList support

(@LiamGoodacre)

There is a new type class in typelevel-prelude called RowToList, which turns
a row of types into a type-level list. This allows us to work with closed
rows in more ways at the type level. The compiler will now solve these constraints
automatically for closed rows of types.

Enhancements

  • Allow things to be hidden from Prim (@garyb)
  • Re-evaluate REPL globs on :reload (@hdgarrood)
  • Include comments in child declarations in HTML docs (@hdgarrood)

IDE Enhancements

  • Collect data constructors (@kRITZCREEK)
  • Adds declarations for Prim (@kRITZCREEK)
  • Repopulates the rebuild cache when populating volatile state (@kRITZCREEK)
  • Add declaration type filter (#2924) (@sectore)
  • Improve reexport bundling (@kRITZCREEK)
  • Resolve synonyms and kinds (@kRITZCREEK)

Bug Fixes

  • Replace synonyms in instance constraints (@LiamGoodacre)
  • Encode PSCI's server content as UTF-8 string (@dgendill)
  • Fix child declaration ordering in docs (@hdgarrood)
  • Improve instance ordering in HTML docs (@hdgarrood)
  • Fix links to type operators in HTML docs (@hdgarrood)

Other

  • Add source span annotations to Declaration (@garyb)
  • Add source span annotations to DeclarationRef (@garyb)
  • Remove purescript.cabal and add to .gitignore (@garyb)
  • Raise upper bound on aeson in package.yaml (@garyb)
  • Only build master and semver tags in Travis (@hdgarrood)
purescript - v0.11.5

Published by paf31 over 7 years ago

Compiler

Enhancements

Type signatures in instances

(@cdepillabout)

Type class instances can now include type signatures for class members, as documentation:

data MyType = MyType String

instance showMyType :: Show MyType where
  show :: MyType -> String
  show (MyType s) = "(MyType " <> show s <> ")"

Bug Fixes

  • Encode HTML content as UTF8 when using purs repl with --port (@dgendill)
  • Disallow some invalid newtype-derived instances (@paf31)
  • Disallow forall within constraints (#2874, @sectore)
  • Convert \r\n into \n after reading files (@kRITZCREEK)
  • Fix PSCi tests (@kRITZCREEK)
  • Better variable naming hygiene in TCO. (#2868, @houli)
  • Simplify TCO generated code (@matthewleon)
  • Remove newlines from printed custom type errors (@matthewleon)
  • Fix some purs command line help message issues (@Cmdv)
  • Apply relative paths during pretty printing of errors (@kRITZCREEK)
  • Desugar let properly when generating docs (@paf31)
  • Fix kind signature for RowCons type class in documentation (@tslawler)
  • Fix an issue with error messages for TypesDoNotUnify involving duplicate labels (#2820, @thoradam)

Other

  • Update package.yaml (@sol)
  • Parse support modules from actual test support purs (@noraesae)
  • Update build command to run tests (@sectore)
  • Bumps lower bound for directory (@kRITZCREEK)
  • Switch core-tests to psc-package (#2830, @matthewleon)
  • Small fix for the copyright dates (@seanwestfall)
  • Update CONTRIBUTING.md for "new contributor" label (@thoradam)

purs ide

Features

  • Add a new namespace filter (#2792, @sectore, @stefanholzmueller)

A new filter, which restricts query results to the value, type and/or kind namespaces, which allows improvements to the completion and import commands.

  • Adds a command to add qualified imports (@kRITZCREEK)

This empowers editor plugins to add imports for qualified identifiers, for example in the Emacs plugin.

  • New import formatting (@kRITZCREEK)
  • Group reexports in completions (@kRITZCREEK)

Editors can now choose to let purs ide group reexports for the same value, to reduce noise when completing values like Data.Functor.map which are reexported a lot and show up that many times in the completion list.

Enhancements

  • Parse modules in parallel (@kRITZCREEK)

This can yield significant speedups in the initial load times. For example a full load of slamdata/slamdata improves from 11 to 6 seconds

  • Introduce completion options (@kRITZCREEK)

Bug Fixes

  • Resolve synonyms and kinds (@kRITZCREEK)
  • Work around laziness when measuring command performance (@kRITZCREEK)
  • Simplify state type (@kRITZCREEK)
  • Extract namespace ADT (@kRITZCREEK)
  • Decodes source files as UTF8 when parsing out the imports (@kRITZCREEK)
  • Fix the import command for kinds (@kRITZCREEK)
  • Reads files in text mode for adding imports (@kRITZCREEK)
  • Add -h/--help to ide subcommands (@simonyangme)
purescript - v0.11.4

Published by paf31 over 7 years ago

Enhancements

  • purs executable will now display help text by default (@matthewleon)
  • Adding -h/--help to ide subcommands (@simonyangme)
  • Some simplifications to the tail call optimization (@matthewleon)

Bug Fixes

  • Remove newline from printed custom type errors (@matthewleon)
  • Fix pretty printing of rows in error messages (#2820, @thoradam)
  • Allow user to propagate Warn constraints (@paf31)
  • Match type level strings in docs renderer (#2772, @hdgarrood)
  • Fix encoding bug in purs ide list import command (@kRITZCREEK)
  • purs ide now reads files in text mode for adding imports (@kRITZCREEK)

Other

  • Bump aeson lower bound to 1.0 (@hdgarrood)
  • Add a bunch of NFData instances (@hdgarrood)
  • Turn off coveralls upload for now (@paf31)
  • purs command line help message fixes (@Cmdv)
  • Switch core-tests to psc-package (#2830, @matthewleon)
  • Update CONTRIBUTING.md notes (@thoradam)
purescript - v0.11.3

Published by paf31 over 7 years ago

Bug Fixes

  • Fix the exhaustivity check for pattern guards (@alexbiehl)

Other

  • Require directory >=1.2.3.0 for XDG support (@bergmark)
  • @noraesae has refactored some PSCi code to improve the test suite.
  • Use hpack to generate the .cabal file (@kRITZCREEK)
  • Use XDG Base Directory Specification for psci_history (@legrostdg)
purescript - v0.11.2

Published by paf31 over 7 years ago

New Features

Polymorphic Labels

(@paf31)

A new RowCons constraint has been added to Prim. RowCons is a 4-way relation between

  1. Symbols
  2. Types
  3. Input rows
  4. Output rows

which appends a new label (1) with the specified type (2) onto the front of the input row (3), to generate a new output row (4). The constraint can also be run backwards to subtract a label from an output row.

This allows us to quantify types over labels appearing at the front of a row type, by quantifying over the corresponding symbol/type pair. This gives us a limited form of polymorphic labels which enables things like writing a single lens for any record accessor.

Enhancements

  • Use XDG Base Directory Specification for the location of the psci_history file (@legrostdg)
  • Collect more information for classes and synonyms in purs ide (@kRITZCREEK)

Bug Fixes

  • Desugar pattern guards after type checking, to avoid an issue with the exhaustivity checker (@alexbiehl)

Other

  • A new PSCi evaluation test suite was added (@noraesae)
  • Use hpack to generate the .cabal file (@kRITZCREEK)
purescript -

Published by paf31 over 7 years ago

Bug Fixes

Compiler

  • Enable TCO for variable intros and assignments #2779 (@paf31)
  • Fixed special case in codegen for guards #2787 (@paf31)

Docs generation

  • Wrap decl title in span for better double-click selection #2786 (@rightfold)
  • List instance info under correct sections, fix #2780 (@paf31)
purescript - v0.11.0

Published by paf31 over 7 years ago

This release includes several breaking changes, in preparation for the 1.0 release, as well as many enhancements and bug fixes.

Most users will probably want to wait until all aspects of the release have been finalized. Progress on libraries and tools is being tracked here.

Many thanks to the contributors who helped with this release!

Breaking Changes

(@garyb, @paf31)

=> now acts like a binary type operator

It was previously possible to specify many constraints in the same context by
separating them with commas inside parentheses on the left of the =>:

runFreeT :: ∀ m f. (Functor f, Monad m) => ...

This is no longer allowed. Instead, => now acts like a binary operator, with a
constraint on the left and a type on the right. Multiple constraints must be
introduced using currying, as with regular function arguments:

runFreeT :: ∀ m f. Functor f => Monad m => ...

This is in preparation for adding constraint kinds, at which point => will become
an actual binary type operator, defined in Prim.

* and ! kinds have been removed

The kind symbols * (for the kind of types) and ! (for the kind of effects) have been
removed from the parser. Instead of *, use Type, which is defined in Prim.
Instead of !, use Effect, which can now be imported from Control.Monad.Eff.

The # symbol, which is used to construct a row kind, is still supported. We cannot move this kind into Prim (because it is polykinded, and we do not support kind polymorphism).

One single consolidated executable

The various psc-* executables have been replaced with a single executable called purs.
The various subcommands are documented on the --help page:

bundle     Bundle compiled PureScript modules for the browser
compile    Compile PureScript source files
docs       Generate Markdown documentation from PureScript source files
hierarchy  Generate a GraphViz directed graph of PureScript type classes
ide        Start or query an IDE server process
publish    Generates documentation packages for upload to Pursuit
repl       Enter the interactive mode (PSCi)

Wrapper scripts will be provided in the binary distribution.

psc-package was removed

psc-package has been removed from the main compiler distribution. It will still
be maintained along with the package sets repo, but will not be bundled with the compiler.

A binary distribution which is compatible with this release is available.

Implicitly discarded values in do blocks now raise errors

Code which discards the result of a computation in a do block:

duplicate :: Array a -> Array a
duplicate xs = do
  x <- xs
  [true, false] -- the result here is discarded
  pure x

will now raise an error. The compiler allows values of certain types to be discarded,
based on the Discard class in Control.Bind. The only type which can be discarded is
Unit, but the feature was implemented using a type class to enable support for
alternative preludes.

No more dependency on the Bower executable

In addition to removing psc-package from the compiler distribution, we have also
removed any explicit dependency on the Bower executable. The compiler will not assume
use of any particular package manager, but will aim to provide generic support for
package managers generally, via command line options and hooks.

purs publish will continue to use the Bower JSON formats. The bower.json format
is now referred to as the "manifest file", while the output of bower list --json,
which is used by purs publish internally, is referred to as the "resolutions file".

Enhancements

Pattern Guards

(@alexbiehl)

In addition to regular guards:

foo x | condition x = ...

the compiler now supports pattern guards, which let the user simultaneously
test a value against a pattern, and bind names to values.

For example, we can apply a function fn to an argument x, succeeding only if
fn returns Just y for some y, binding y at the same time:

bar x | Just y <- fn x = ... -- x and y are both in scope here

Pattern guards can be very useful for expressing certain types of control flow when
using algebraic data types.

HTML Documentation

(@hdgarrood)

The --format html option has been added to purs docs. The HTML format uses
the Pursuit template, and is very useful for rendering documentation for offline
use.

Here is an example of the generated HTML.

Duplicate Labels

(@paf31)

Row types now support duplicate labels, which can be useful when using the Eff
monad. For example, we could not previously use the catchException function if
the resulting action also required the EXCEPTION effect, since otherwise the
type of the inner action would contain a duplicate label.

Rows are now unordered collections (of labels and types) with duplicates. However,
the collection of types for a specific label within a row is ordered.
Conceptually, a row can be thought of as a type-level Map Label (NonEmptyList Type).

A type constructor (such as Record) which takes a row of types as an argument should
define what its meaning is on each row. The meaning of a value of type Record r
is a JavaScript object where the type of the value associated with each label is given
by the head element of the non-empty list of types for that label.

Row Constraints

(@doolse, @paf31)

A new constraint called Union has been added to Prim. Union is a three-way relation between
rows of types, and the compiler will solve it automatically when it is possible to do so.

Union is a left-biased union of rows which takes into account duplicate labels. If the same label appears in rows l and r, and Union l r u holds, then the label will appear twice in u.

Union makes it possible to give a type to the function which merges two records:

merge :: forall r1 r2 r3. Union r1 r2 r3 => Record r1 -> Record r2 -> Record r3

Note that this is a left-biased merge - if the two input record contain a common label, the type of the
label in the result will be taken from the left input.

Patterns in let expressions

(@noraesae)

Let expressions and where clauses can now use binders on the left hand side of
a declaration:

map f xs = 
  let { head, tail } = uncons xs
  in [f head] <> map f tail

Unlike in Haskell, declarations with these patterns cannot appear in dependency cycles, and bound names can only be used in declarations after the one in which they are brought into scope.

Find record accessors in Type Directed Search

(@kRITZCREEK)

Type-directed search will now include results for record accessors. This can
be very useful when working with extensible records with a type-driven programming
workflow.

Other Enhancements

  • Add basic usability check and error for ambiguously-typed type class members (@LiamGoodacre)
  • Improved skolem escape check (@paf31)
  • Fix links to declarations in Prim (@hdgarrood)
  • Emit _ instead of false case for if then else to improve optimizations (@rightfold)
  • Add InvalidDerivedInstance error to improve errors for derived instances (@paf31)
  • Make generated code for superclass instances less ugly (@paf31)
  • Support polymorphic types in typed binders (@paf31)
  • Make file paths relative in error messages (@paf31)
  • Improve errors from module sorter (@paf31)
  • Improve error for unused type variables (@paf31)
  • Include source span in externs file for error reporting purposes (@paf31)
  • Improve instance arity errors (@mrkgnao)

purs ide

Features

Improve import parsing

  • purs ide now uses a new import parser, which allows purs ide to handle any
    import section that the compiler would accept correctly. (@kRITZCREEK)
  • Parse imports with hanging right paren (@matthewleon)
  • Reuses lenient import parsing for the list import command (@kRITZCREEK)

Don't create the output/ directory if it can't be found

(@kRITZCREEK)

purs ide will now no longer leave empty output/ directories behind when it is
started in a directory that is not a PureScript project.

Collect type class instances

(@kRITZCREEK)

purs ide collects instances and stores them with their respective type class.
There's no way to retrieve these yet, but we will extend the protocol soon.

Bug Fixes

  • No longer strip trailing dots for Pursuit queries (@kRITZCREEK)
  • Fix #2537 (psc-ide shouldn't crash when building a non-existent file) (@kRITZCREEK)
  • Fix #2504 (fix a crash related to prematurely closed handles) (@kRITZCREEK)
  • Speed up rebuilding by x2, by rebuilding with open exports asynchronously (@kRITZCREEK)
  • Return operators in purs ide imports list (@nwolverson)
  • Also detect location information for operators (@kRITZCREEK)

Cleanup

  • Removes unnecessary clause in import pretty printing (@kRITZCREEK)
  • Removes the deprecated --debug option (@kRITZCREEK)
  • Restructure testing to avoid running the server (@kRITZCREEK)

purs repl

  • Add back .purs-repl file support (@paf31)
  • PSCi command changes, add :clear (@noraesae)
  • Declarations no longer require let (@noraesae)
  • Improve CLI error and startup messages (@noraesae)

Bug Fixes

  • Changes to help the tail call optimization fire more consistently (@paf31)
  • Fix everythingWithScope traversal bug #2718 (@paf31)
  • Errors for open rows in derived instances (@paf31)
  • Instantiate types in record literals as necessary (@paf31)
  • Fix Generic deriving with synonyms (@paf31)
  • Rebuild modules if necessary when using --dump-corefn (@paf31)
  • Ensure solved type classes are imported (@LiamGoodacre)
  • Allow for older Git versions in purs publish (@mcoffin)
  • Fix purs publish --dry-run (@hdgarrood)
  • Exported data constructors can now contain quotes (@LiamGoodacre)

Documentation

  • Capitalise *script into *Script (@noraesae)

Performance

  • Optimize keepImp (@paf31)
  • Replace nub with ordNub (@matthewleon)
  • Combine inlining optimizations into a single pass (@paf31)

Other

  • Add HasCallStack to internalError (@alexbiehl)
  • Use Stackage LTS 8.0 (@noraesae)
  • Address Travis timeout issues (@hdgarrood)
  • Improve module structure in PSCi test suite (@noraesae)
  • Fix the PSCi script (@mrkgnao)
  • Include Git commit information in non-release builds (@hdgarrood)
  • Add test case for #2756 (@int-index)
  • Some code cleanup in the module imports phase (@matthewleon)
purescript - v0.11.0-rc.1

Published by paf31 over 7 years ago

Release candidate. Use 0.11.0 instead.

purescript - v0.10.7

Published by paf31 over 7 years ago

This release contains a bug fix for a bug in psc-bundle which was introduced in 0.10.6.

purescript - v0.10.6

Published by paf31 over 7 years ago

Enhancements

  • Add support for user defined warnings via the Warn type class (@LiamGoodacre, blog post)
  • Support nested record update (@LiamGoodacre, blog post)
  • Inline unsafePartial (@paf31)
  • Fail early when bind is brought into scope inside do (@paf31)

Bug Fixes

  • Disallow polymorphic types in binders, preventing a crash (@paf31)
  • Rebuild modules if necessary when using --dump-corefn (@paf31)
  • TypeLevelString/TypeConcat should not be quoted (@michaelficarra)
  • Generate JS static member accesses whenever possible (@michaelficarra)
  • Require dependencies to exist during sorting phase (@paf31)
  • Fix inlining for negateInt (@paf31)
  • Fix object key quoting (@hdgarrood)
  • Don't expand synonyms until after kind checking (@paf31)
  • Fix 'Unknown type index' on mismatch between class and instance argument counts (@LiamGoodacre)
  • Style comment types differently (@matthewleon)

psc-ide

  • Return operators in psc-ide imports list (@nwolverson)
  • Collect type class instances (@kRITZCREEK)
  • Log failing to accept or parse an incoming command (@kRITZCREEK)
  • Fix #2537 (@kRITZCREEK)
  • Fix #2504 (@kRITZCREEK)
  • Also detect location information for operators (@kRITZCREEK)
  • Speeds up rebuilding by x2 (@kRITZCREEK)
  • Restructure testing to avoid running the server (@kRITZCREEK)

psc-publish

  • Add modules for rendering HTML documentation (@hdgarrood)
  • Fix psc-publish --dry-run (@hdgarrood)
  • Fix failure to parse git tag date in psc-publish (@hdgarrood)
  • Add git tag time to psc-publish JSON (@hdgarrood)
  • Remove Docs.Bookmarks (@hdgarrood)

Performance

  • Combine inlining optimizations into a single pass (@paf31)
  • Use Map.foldlWithKey' instead of foldl (@hdgarrood)
  • Minor memory usage improvements in Language.PureScript.Docs (@hdgarrood)

Other

  • Generate data constructors without IIFEs (@hdgarrood)
  • Add stack-ghc-8.0.2.yaml (@noraesae)
  • Add HasCallStack to internalError (@alexbiehl)
  • Update psc-package to use turtle 1.3 (@taktoa)
  • Remove JSAccessor; replace with JSIndexer (@michaelficarra)
  • Store more information in RenderedCode (@hdgarrood)
purescript - v0.10.5

Published by paf31 almost 8 years ago

Enhancements

  • Adds specific error message when failing to import bind (@FrigoEU)

Bug Fixes

  • Detect conflicting data constructor names (@LiamGoodacre)
  • Update pretty printer for Kinds (@hdgarrood)
  • Restore JSON backwards compatibility for PSString (@hdgarrood)
  • Replace type wildcards earlier (@paf31)
  • Restore backwards compatibility for parsing Kinds (@hdgarrood)

Other

  • Update bower-json to 1.0.0.1 (@hdgarrood)
purescript - v0.10.4

Published by paf31 almost 8 years ago

New Features

Deriving Functor

(@LiamGoodacre, #2515)

The Functor type class can now be derived using the standard derive instance syntax:

newtype F a = F { foo :: Array a, bar :: a }

derive instance functorF :: Functor F 

User-Defined Kinds

(@LiamGoodacre, #2486)

Custom kinds can now be defined using the foreign import kind syntax:

foreign import kind SymbolList

Custom kinds can be ascribed to types using foreign import data declarations, as usual:

foreign import data Nil :: SymbolList
foreign import data Cons :: Symbol -> SymbolList -> SymbolList

Note that kind arguments are not supported.

User defined kinds can be imported/exported using the kind prefix, for example:

import Type.SymbolList (kind SymbolList)

Source Maps in psc-bundle

(@nwolverson)

psc-bundle will now generate source maps if the--source-maps flag is used.

Solving CompareSymbol and AppendSymbol

(@LiamGoodacre, #2511)

Support for the new purescript-typelevel-prelude library has been added to the compiler. CompareSymbol and AppendSymbol constraints will now be solved automatically for literal symbols.

New psc-package Features

(@paf31)

Two new commands have been added to psc-package to support library authors and package set curators.

  • The updates command (#2510) is used to update packages in the set.
  • The verify-set command (#2459) is used to verify the health of a package set. This command replicates the work done by the package-sets CI job, and can be used to test modifications to the package set locally before making a pull request.

Enhancements

  • Update orphan instance check to use covering sets when functional dependencies are involved (@LiamGoodacre)
  • Add --node-path option to PSCi to modify the path to the Node executable (#2507, @paf31)
  • Add package information to re-exports (@hdgarrood)
  • Add Prim docs to the library (#2498, @hdgarrood)

Bug Fixes

  • Derive instances when data types use type synonyms (#2516, @paf31)
  • Unwrap KindedType when instance solving (@LiamGoodacre)
  • Update links to wiki (#2476, @LiamGoodacre)
  • Update websocket host to fix PSCi on Windows (#2483, @seungha-kim)
  • Fix psc-ide tests on windows (@kRITZCREEK)
  • Fix some issues with the pretty printer (#2039, @paf31)

Other

  • More robust license generator script (@hdgarrood)
  • Further conversions to Text in the Docs modules (#2502, @hdgarrood)
  • Add upper bound on turtle, fixes #2472, (@hdgarrood)
  • Fix version bounds on language-javascript (@hdgarrood)
purescript - v0.10.3

Published by paf31 almost 8 years ago

Enhancements

Solving IsSymbol instances

(@LiamGoodacre)

The compiler will now derive Data.Symbol.IsSymbol instances for type-level string literals.

This enables interesting type-level programming features, such as deriving Show instances using Data.Generics.Rep.

Rows in Instance Heads

(@LiamGoodacre)

The compiler now allows rows to appear in type class instance heads, but only in type arguments which are fully determined by some functional dependency.

This allows instances like

MonadState { field :: Type } MyAppMonad

and also Newtype instances for newtypes which contain records.

Speeds up parsing by reading files as Text

(@kRITZCREEK)

The use of String has been replaced by Text in the compiler, resulting in some non-trivial performance improvements.

Functional Dependencies in psc-docs output

(@soupi, #2439)

psc-docs now includes functional dependency information when rendering type classes.

New psc-package Commands

  • The available command (@andyarvanitis) shows all available packages in the current package set
  • The uninstall command (@joneshf) removes a package from the set of active packages and updates the package configuration file.

Type Class Warning (@joneshf)

A warning was added for shadowed type variables in type class declarations.

Bug Fixes

  • psc-package: display full path in 'packages.json does not exist' error messsage (@andyarvanitis)
  • Use writeUTF8File in psc-bundle (@hdgarrood)
  • Use HTTPS to query Pursuit (@paf31)
  • Moved the expansion of astral code points to UTF-16 surrogate pairs from the JS code generator to the parser (@michaelficarra, #2434)
  • Allow astral code points in record literal keys (@michaelficarra, #2438)
  • Add value source positions (@nwolverson)
  • Update error message of ErrorInDataBindingGroup to include participating identifiers (@LiamGoodacre)

psc-ide

  • Polling option for psc-ide-server (@kRITZCREEK)
  • Better logging and diagnostics (@kRITZCREEK)

Other

  • Dump output of psc tests to file (@andyarvanitis, #2453)
  • Fix windows CI (@hdgarrood)
  • Link to new documentation repo (@hdgarrood)
  • Create documentation for psc-package (@paf31)
  • Fix GHC 8.0.2 build (@RyanGlScott)
  • Add psc-package to release bundle (@marsam)
  • Update for latest language-javascript (@tmcgilchrist)
  • Fix exhaustivity warnings (@charleso)
  • Update CONTRIBUTING.md (@osa1)
purescript - v0.10.2

Published by paf31 almost 8 years ago

Major Changes

Type-directed search (@kRITZCREEK)

This extends the typed holes error messages to include suggested replacements for a typed hole, by using type subsumption to determine which identifiers in scope are appropriate replacements.

A blog post will accompany this feature soon.

psc-package (@paf31)

This is an experimental package manager for PureScript packages. It supports the following commands:

  • init - create a new project using the package set for the current compiler version
  • update - sync the local package collection with the package set
  • install - install a specific package from the current set and add it to the package config
  • build - run psc on any active packages
  • sources - list source globs for active package versions
  • dependencies - list transitive dependencies of the current project

For example:

$ psc-package init
$ psc-package install transformers
$ psc-package build

Eventually, psc-package might replace the use of Bower, but that will require support from tools like Pulp. For now, package authors should continue to publish packages using Bower and Pursuit.

Data.Generic.Rep.Generic Deriving (@paf31)

This is an alternative generic programming implementation based on GHC.Generics. It should allow deriving of more interesting classes, such as Semigroup. See the purescript-generics-rep package for examples.

Enhancements

  • #2323: Sort IDE-generated explicit imports (@bbqbaron)
  • #2374: Add error message for ambiguous type variables in inferred contexts (@bbqbaron)
  • #934 Add paste mode, remove --multi-line option (@paf31)
  • Allow symbols in data constructors (@brandonhamilton)
  • Fix inliner for integer bitwise operators (@brandonhamilton)
  • Use SSL for pursuit queries (@guido4000)

Bug Fixes

  • #2370, allow rows in instance contexts (@paf31)
  • #2379, add error message for unknown classes (@paf31)
  • Better error messages for bad indentation (@paf31)
  • Fix inliner for Data.Array.unsafeIndex (@brandonhamilton)
  • Fix issue with typed holes in inference mode (@paf31)
  • Fix scope traversal for do-notation bind. (@LiamGoodacre)
  • Handle TypeLevelString when checking orphans (@joneshf)
  • Move unsafeIndex to Data.Array (@brandonhamilton)
  • Pretty-print suggested types differently (@paf31)
  • Traversal should pick up bindings in all value declarations. (@LiamGoodacre)
  • Treat type annotations on top-level expressions as if they were type declarations (@paf31)

Other

  • Refactor subsumes function (@paf31)
  • Refactor to use lens (@kRITZCREEK)
  • Small cleanup to Language.PureScript.Interactive.IO (@phiggins)
  • Speeds up parsing by reading files as Text (@kRITZCREEK)
  • Update outdated comments about Prim types (@rightfold)