内容简介:Idris 2 v0.4.0 发布。此版本主要变更包括语法变化、编译器变更、REPL/IDE 模式变更。 语法变化 Desugar non-binding sequencing in do blocks to (>>) (#1095) Multiline Strings with """ as delimiters (#109...
Idris 2 v0.4.0 发布。此版本主要变更包括语法变化、编译器变更、REPL/IDE 模式变更。
语法变化
- Desugar non-binding sequencing in do blocks to (
>>) (#1095) - Multiline Strings with
"""as delimiters (#1097) - Force strict indentation after usage of
withkeyword (#1107) - The syntax for parameter blocks has been updated. It now allows to declare implicit parameters and give multiplicities for parameters. The old syntax is still available for compatibility purposes but will be removed in the future.
- Add support for SnocList syntax:
[< 1, 2, 3]desugars intoLin :< 1 :< 2 :< 3and their semantic highlighting. - Underscores can be used as visual separators for digit grouping purposes in integer literals:
10_000_000is equivalent to10000000and0b1111_0101_0000is equivalent to0b111101010000. This can aid readability of long literals, or literals whose value should clearly separate into parts, such as bytes or words in hexadecimal notation.
编译器变化
- Added more optimisations and transformations, particularly on case blocks, list-shaped types, and enumerations, so generated code will often be slightly faster.
- Added
--profileflag, which generates profile data if supported by a back end. Currently supported by the Chez and Racket back ends. - New
%builtinpragma for compiling user defined natural numbers to primitiveIntegers (see the docs) - The
versionfield in.ipkgfiles is now used. Packages are installed into a directory which includes its version number, and dependencies can have version number ranges using<=,<,>=,>,==to express version constraints. Version numbers must be in the form of integers, separated by dots (e.g.1.0,0.3.0,3.1.4.1.5etc) - Idris now looks in the current working directory, under a subdirectory
dependsfor local installations of packages before looking globally. - Added an environment variable
IDRIS2_PACKAGE_PATHfor extending where to look for packages. - Added compiler warnings flags (
-Wprefix):-Wno-shadowing: disable shadowing warnings.-Werror: treat warnings as errors.
- Experimental flag (
-Xcheck-hashes) to check hashes instead of filesystem times to determine if files should be recompiled. Should help with CI/CD caching.
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:- 编程语言特性:函数
- Go 语言函数式编程系列教程(十八) —— 函数篇:函数的基本定义和调用
- Go 语言函数式编程系列教程(十九) —— 函数篇:函数的传参和返回值
- Elixir 1.8 发布,函数式编程语言
- OCaml 4.08.0 发布,函数式编程语言
- OCaml 4.09.0 发布,函数式编程语言
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
白帽子讲浏览器安全
钱文祥 / 电子工业出版社 / 2016-3 / 79.00元
浏览器是重要的互联网入口,一旦受到漏洞攻击,将直接影响到用户的信息安全。作为攻击者有哪些攻击思路,作为用户有哪些应对手段?在《白帽子讲浏览器安全》中我们将给出解答,带你了解浏览器安全的方方面面。《白帽子讲浏览器安全》兼顾攻击者、研究者和使用者三个场景,对大部分攻击都提供了分析思路和防御方案。《白帽子讲浏览器安全》从攻击者常用技巧的“表象”深入介绍浏览器的具体实现方式,让你在知其然的情况下也知其所以......一起来看看 《白帽子讲浏览器安全》 这本书的介绍吧!
