PureScript 0.10.4 发布了,PureScript 是个小巧而强大的静态类型语言,可以编译成 JavaScript。PureScript 主要是由 Haskell 和 PureScript 编写的。
主要更新内容:
新功能
Deriving Functor:
The
Functor
type class can now be derived using the standardderive instance
syntax:newtype F a = F { foo :: Array a, bar :: a } derive instance functorF :: Functor F
User-Defined Kinds:
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
Source Maps in
psc-bundle
:psc-bundle
will now generate source maps if the--source-maps
flag is used.Solving
CompareSymbol
andAppendSymbol
:Support for the newpurescript-typelevel-prelude
library has been added to the compiler.CompareSymbol
andAppendSymbol
constraints will now be solved automatically for literal symbols.New
psc-package
Features
完整更新内容请查看发行日志
下载地址: