设为首页收藏本站

LUPA开源社区

 找回密码
 注册
文章 帖子 博客
LUPA开源社区 首页 业界资讯 软件追踪 查看内容

Julia 0.6.0发布,动态编程语言

2017-6-21 22:26| 发布者: joejoe0332| 查看: 642| 评论: 0|原作者: oschina|来自: oschina

摘要: Julia 0.6.0 发布了。Julia是一个新的高性能动态高级编程语言。语法和其他编程语言类似,易于其他语言用户学习。Julia拥有丰富的函数库,提供了数字精度、精致的增幅 器(sophisticated amplifier)和分布式并行运行 ...

Julia 0.6.0 发布了。Julia是一个新的高性能动态高级编程语言。语法和其他编程语言类似,易于其他语言用户学习。Julia拥有丰富的函数库,提供了数字精度、精致的增幅 器(sophisticated amplifier)和分布式并行运行方式。核心函数库等大多数库是由Julia编写,但也用成熟的C和FORTRAN库来处理线性代数、随机数产生和字 符串处理等问题。Julia语言可定义函数并且根据用户自定义的参数类型组合再进行重载。

新的语言特性:

New type system capabilities (#8974#18457)

  • Type parameter constraints can refer to previous parameters, e.g. type Foo{R<:Real, A<:AbstractArray{R}}. Can also be used in method definitions.

  • New syntax Array{T} where T<:Integer, indicating a union of types over all specified values of T (represented by a UnionAll type). This provides behavior similar to parametric methods or typealias, but can be used anywhere a type is accepted. This syntax can also be used in method definitions, e.g. function inv(M::Matrix{T}) where T<:AbstractFloat. Anonymous functions can have type parameters via the syntax ((x::Array{T}) where T<:Real) -> 2x.

  • Implicit type parameters, e.g. Vector{<:Real} is equivalent to Vector{T} where T<:Real, and similarly for Vector{>:Int} (#20414).

  • Much more accurate subtype and type intersection algorithms. Method sorting and identification of equivalent and ambiguous methods are improved as a result.

语言变化:

  • "Inner constructor" syntax for parametric types is deprecated. For example, in this definition:

    type Foo{T,S<:Real}
        x
        Foo(x) = new(x)
    end

    the syntax Foo(x) = new(x) actually defined a constructor for Foo{T,S}, i.e. the case where the type parameters are specified. For clarity, this definition now must be written as Foo{T,S}(x) where {T,S<:Real} = new(x) (#11310#20308).

  • The keywords used to define types have changed (#19157#20418).

    In 0.6, immutable and type are still allowed as synonyms without a deprecation warning.

    • immutable changes to struct

    • type changes to mutable struct

    • abstract changes to abstract type ... end

    • bitstype 32 Char changes to primitive type Char 32 end

  • ……

完整更新内容请查看更新日志

下载地址:


酷毙

雷人
1

鲜花

鸡蛋

漂亮

刚表态过的朋友 (1 人)

  • 快毕业了,没工作经验,
    找份工作好难啊?
    赶紧去人才芯片公司磨练吧!!

最新评论

关于LUPA|人才芯片工程|人才招聘|LUPA认证|LUPA教育|LUPA开源社区 ( 浙B2-20090187 浙公网安备 33010602006705号   

返回顶部