You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Packages that define custom exception types can support hints by
22
-
calling the `Base.Experimental.show_error_hints` from their
23
-
`showerror` method. ([#35094])
24
-
25
17
* Support for Unicode 13.0.0 (via utf8proc 2.5) ([#35282]).
26
-
27
18
* The compiler optimization level can now be set per-module using the experimental macro
28
19
`Base.Experimental.@optlevel n`. For code that is not performance-critical, setting
29
20
this to 0 or 1 can provide significant latency improvements ([#34896]).
@@ -37,28 +28,16 @@ Language changes
37
28
[IJulia](https://github.com/JuliaLang/IJulia.jl).
38
29
Note that this only affects expressions interactively typed or pasted directly into the
39
30
default REPL ([#28789], [#33864]).
40
-
41
31
* Outside of the REPL (e.g. in a file), assigning to a variable within a top-level scope
42
32
block is considered ambiguous if a global variable with the same name exists.
43
33
A warning is given if that happens, to alert you that the code will work differently
44
34
than in the REPL.
45
35
A new command line option `--warn-scope` controls this warning ([#33864]).
46
-
47
36
* Converting arbitrary tuples to `NTuple`, e.g. `convert(NTuple, (1, ""))` now gives an error,
48
37
where it used to be incorrectly allowed. This is because `NTuple` refers only to homogeneous
49
38
tuples (this meaning has not changed) ([#34272]).
50
-
51
-
* In docstrings, a level-1 markdown header "Extended help" is now
52
-
interpreted as a marker dividing "brief help" from "extended help."
53
-
The REPL help mode only shows the brief help (the content before the
54
-
"Extended help" header) by default; prepend the expression with '?'
55
-
(in addition to the one that enters the help mode) to see the full
56
-
docstring. ([#25930])
57
-
58
39
* The syntax `(;)` (which was deprecated in v1.4) now creates an empty named tuple ([#30115]).
59
-
60
40
*`@inline` macro can now be applied to short-form anonymous functions ([#34953]).
61
-
62
41
* In triple-quoted string literals, whitespace stripping is now done before processing
63
42
escape sequences instead of after. For example, the syntax
64
43
```
@@ -68,14 +47,12 @@ Language changes
68
47
used to yield the string " a\nb", since the single space before `b` set the indent level.
69
48
Now the result is "a\n b", since the space before `b` is no longer considered to occur
70
49
at the start of a line. The old behavior is considered a bug ([#35001]).
71
-
72
50
* The line number of function definitions is now added by the parser as an
73
51
additional `LineNumberNode` at the start of each function body ([#35138]).
74
-
75
52
* Statements of the form `a'` now get lowered to `var"'"(a)` instead of `Base.adjoint(a)`. This
76
53
allows for shadowing this function in local scopes, although this is generally discouraged.
77
54
By default, Base exports `var"'"` as an alias of `Base.adjoint`, so custom types should still
78
-
extend `Base.adjoint`. ([#34634])
55
+
extend `Base.adjoint` ([#34634]).
79
56
80
57
Compiler/Runtime improvements
81
58
-----------------------------
@@ -92,15 +69,13 @@ Command-line option changes
92
69
93
70
* Deprecation warnings are no longer shown by default. i.e. if the `--depwarn=...` flag is
94
71
not passed it defaults to `--depwarn=no`. The warnings are printed from tests run by
95
-
`Pkg.test()`. ([#35362]).
96
-
97
-
* Color now defaults to on when stdout and stderr are TTYs ([#34347])
98
-
72
+
`Pkg.test()` ([#35362]).
73
+
* Color now defaults to on when stdout and stderr are TTYs ([#34347]).
99
74
*`-t N`, `--threads N` starts Julia with `N` threads. This option takes precedence over
100
75
`JULIA_NUM_THREADS`. The specified number of threads also propagates to worker
101
76
processes spawned using the `-p`/`--procs` or `--machine-file` command line arguments.
102
77
In order to set number of threads for worker processes spawned with `addprocs` use the
103
-
`exeflags` keyword argument, e.g. ``addprocs(...; exeflags=`--threads 4`)`` ([#35108]).
78
+
`exeflags` keyword argument, e.g. ```addprocs(...; exeflags=`--threads 4`)``` ([#35108]).
104
79
105
80
Multi-threading changes
106
81
-----------------------
@@ -114,35 +89,40 @@ Multi-threading changes
114
89
115
90
Build system changes
116
91
--------------------
117
-
* The build system now contains a pure-make caching system for expanding expensive operations at the latest
118
-
possible moment, while still expanding it only once. ([#35626])
119
92
93
+
* The build system now contains a pure-make caching system for expanding expensive operations at the latest
94
+
possible moment, while still expanding it only once ([#35626]).
120
95
121
96
New library functions
122
97
---------------------
123
-
* The `@ccall` macro has been added to Base. It is a near drop-in replacement for `ccall` with more Julia-like syntax. It also wraps the new `foreigncall` API for varargs of different types, though it lacks the capability to specify an LLVM calling convention. ([#32748])
98
+
99
+
* Packages can now provide custom hints to help users resolve errors by using the
Packages that define custom exception types can support hints by calling the
102
+
`Base.Experimental.show_error_hints` from their `showerror` method ([#35094]).
103
+
* The `@ccall` macro has been added to Base. It is a near drop-in replacement for `ccall` with more Julia-like syntax. It also wraps the new `foreigncall` API for varargs of different types, though it lacks the capability to specify an LLVM calling convention ([#32748]).
124
104
* New functions `mergewith` and `mergewith!` supersede `merge` and `merge!` with `combine`
125
105
argument. They don't have the restriction for `combine` to be a `Function` and also
126
106
provide one-argument method that returns a closure. The old methods of `merge` and
127
107
`merge!` are still available for backward compatibility ([#34296]).
128
108
* The new `isdisjoint` function indicates whether two collections are disjoint ([#34427]).
129
-
* Add function `ismutable` and deprecate `isimmutable` to check whether something is mutable.([#34652])
109
+
* Add function `ismutable` and deprecate `isimmutable` to check whether something is mutable([#34652]).
130
110
*`include` now accepts an optional `mapexpr` first argument to transform the parsed
131
111
expressions before they are evaluated ([#34595]).
132
112
* New function `bitreverse` for reversing the order of bits in a fixed-width integer ([#34791]).
133
113
* New function `bitrotate(x, k)` for rotating the bits in a fixed-width integer ([#33937]).
134
-
* One argument methods `startswith(x)` and `endswith(x)` have been added, returning partially-applied versions of the functions, similar to existing methods like `isequal(x)` ([#33193]).
135
-
* New function `contains(haystack, needle)` and its one argument partially applied form have been added, it acts like `occursin(needle, haystack)`([#35132]).
114
+
* New function `contains(haystack, needle)` and its one argument partially applied form have been added, it acts like `occursin(needle, haystack)` ([#35132]).
136
115
* New function `Base.exit_on_sigint` is added to control if `InterruptException` is
137
116
thrown by Ctrl-C ([#29411]).
138
117
139
118
New library features
140
119
--------------------
141
-
* Function composition now works also on one argument `∘(f) = f` (#34251)
142
-
*`@NamedTuple{key1::Type1, ...}` macro for convenient `NamedTuple` declarations ([#34548]).
143
120
121
+
* Function composition now works also on one argument `∘(f) = f` (#34251).
122
+
* One argument methods `startswith(x)` and `endswith(x)` have been added, returning partially-applied versions of the functions, similar to existing methods like `isequal(x)` ([#33193]).
144
123
*`isapprox` (or `≈`) now has a one-argument "curried" method `isapprox(x)` which returns a function, like `isequal` (or `==`) ([#32305]).
145
-
*`Ref{NTuple{N,T}}` can be passed to `Ptr{T}`/`Ref{T}``ccall` signatures ([#34199])
124
+
*`@NamedTuple{key1::Type1, ...}` macro for convenient `NamedTuple` declarations ([#34548]).
125
+
*`Ref{NTuple{N,T}}` can be passed to `Ptr{T}`/`Ref{T}``ccall` signatures ([#34199]).
146
126
*`x::Signed % Unsigned` and `x::Unsigned % Signed` are supported for integer bitstypes.
147
127
*`signed(unsigned_type)` is supported for integer bitstypes, `unsigned(signed_type)` has been supported.
148
128
*`accumulate`, `cumsum`, and `cumprod` now support `Tuple` ([#34654]) and arbitrary iterators ([#34656]).
@@ -152,16 +132,17 @@ New library features
152
132
* The `@view` and `@views` macros now support the `a[begin]` syntax that was introduced in Julia 1.4 ([#35289]).
153
133
*`open` for files now accepts a keyword argument `lock` controlling whether file operations
154
134
will acquire locks for safe multi-threaded access. Setting it to `false` provides better
155
-
performance when only one thread will access the file.
135
+
performance when only one thread will access the file ([#35426]).
156
136
* The introspection macros (`@which`, `@code_typed`, etc.) now work with `do`-block syntax ([#35283]) and with dot syntax ([#35522]).
157
137
*`count` now accepts the `dims` keyword.
158
138
* new in-place `count!` function similar to `sum!`.
159
139
160
140
Standard library changes
161
141
------------------------
142
+
162
143
* Empty ranges now compare equal, regardless of their startpoint and step ([#32348]).
163
144
* A 1-d `Zip` iterator (where `Base.IteratorSize` is `Base.HasShape{1}()`) with defined length of `n` has now also size of `(n,)` (instead of throwing an error with truncated iterators) ([#29927]).
164
-
* The `@timed` macro now returns a `NamedTuple` ([#34149])
145
+
* The `@timed` macro now returns a `NamedTuple` ([#34149]).
165
146
* New `supertypes(T)` function returns a tuple of all supertypes of `T` ([#34419]).
166
147
* Views of builtin ranges are now recomputed ranges (like indexing returns) instead of
167
148
`SubArray`s ([#26872]).
@@ -176,55 +157,60 @@ Standard library changes
176
157
contents ([#31149]).
177
158
178
159
#### LinearAlgebra
160
+
179
161
* The BLAS submodule now supports the level-2 BLAS subroutine `hpmv!` ([#34211]).
180
-
*`normalize` now supports multidimensional arrays ([#34239])
162
+
*`normalize` now supports multidimensional arrays ([#34239]).
181
163
*`lq` factorizations can now be used to compute the minimum-norm solution to under-determined systems ([#34350]).
182
164
* The BLAS submodule now supports the level-2 BLAS subroutine `spmv!` ([#34320]).
183
165
* The BLAS submodule now supports the level-1 BLAS subroutine `rot!` ([#35124]).
184
166
* New generic `rotate!(x, y, c, s)` and `reflect!(x, y, c, s)` functions ([#35124]).
185
167
186
168
#### Markdown
187
169
170
+
* In docstrings, a level-1 markdown header "Extended help" is now interpreted as a marker
171
+
dividing "brief help" from "extended help". The REPL help mode only shows the brief help
172
+
(the content before the "Extended help" header) by default; prepend the expression with '?'
173
+
(in addition to the one that enters the help mode) to see the full docstring ([#25930]).
188
174
189
175
#### Random
190
176
191
177
*`randn!(::MersenneTwister, ::Array{Float64})` is faster, and as a result, for a given state of the RNG,
192
178
the corresponding generated numbers have changed ([#35078]).
193
-
194
179
*`rand!(::MersenneTwister, ::Array{Bool})` is faster, and as a result, for a given state of the RNG,
195
180
the corresponding generated numbers have changed ([#33721]).
196
-
197
181
* A new faster algorithm ("nearly division less") is used for generating random numbers
198
182
within a range ([#29240]). As a result, the streams of generated numbers are changed
199
183
(for ranges, like in `rand(1:9)`, and for collections in general, like in `rand([1, 2, 3])`).
200
184
Also, for performance, the undocumented property that, given a seed and `a, b` of type `Int`,
201
185
`rand(a:b)` produces the same stream on 32 and 64 bits architectures, is dropped.
202
186
203
-
204
187
#### REPL
205
188
206
189
207
190
#### SparseArrays
191
+
208
192
*`lu!` accepts `UmfpackLU` as an argument to make use of its symbolic factorization.
209
193
* The `trim` keyword argument for the functions `fkeep!`, `tril!`, `triu!`,
210
194
`droptol!`,`dropzeros!` and `dropzeros` has been removed in favour of always
211
195
trimming. Calling these with `trim=false` could result in invalid sparse
212
196
arrays.
213
197
214
198
#### Dates
199
+
215
200
* The `eps` function now accepts `TimeType` types ([#31487]).
216
201
* The `zero` function now accepts `TimeType` types ([#35554]).
217
202
218
-
219
203
#### Statistics
220
204
221
205
222
206
#### Sockets
207
+
223
208
* Joining and leaving UDP multicast groups on a `UDPSocket` is now supported
224
209
through `join_multicast_group()` and `leave_multicast_group()` ([#35521]).
225
210
226
211
#### Distributed
227
-
*`launch_on_machine` now supports and parses ipv6 square-bracket notation ([#34430])
212
+
213
+
*`launch_on_machine` now supports and parses ipv6 square-bracket notation ([#34430]).
0 commit comments