Skip to content

Commit 7387f65

Browse files
committed
Merge remote-tracking branch 'origin/master' into ajf/view-of-range
* origin/master: (833 commits) Improve typesubtract for tuples (#35600) Make searchsorted*/findnext/findprev return values of keytype (#32978) fix buggy rand(RandomDevice(), Bool) (#35590) remove `Ref` allocation on task switch (#35606) Revert "partr: fix multiqueue resorting stability" (#35589) exclude types with free variables from `type_morespecific` (#35555) fix small typo in NEWS.md (#35611) enable inline allocation of structs with pointers (#34126) SparseArrays: Speed up right-division by diagonal matrices (#35533) Allow hashing 1D OffsetArrays NEWS item for introspection macros (#35594) Special case empty covec-diagonal-vec product (#35557) [GCChecker] fix a few tests by looking through casts Use norm instead of abs in generic lu factorization (#34575) [GCChecker,NFC] run clang-format -style=llvm [GCChecker] fix tests and add Makefile Add introspection macros support for dot syntax (#35522) Specialize `union` for `OneTo` (#35577) add pop!(vector, idx, [default]) (#35513) bump Pkg version (#35584) ...
2 parents 40d3bdd + 01155e1 commit 7387f65

File tree

1,480 files changed

+29831
-32462
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,480 files changed

+29831
-32462
lines changed

.devcontainer/Dockerfile

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
FROM julia:latest
2+
3+
RUN apt-get update && apt-get install -y build-essential libatomic1 python gfortran perl wget m4 cmake pkg-config git

.devcontainer/devcontainer.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"extensions": [
3+
"julialang.language-julia",
4+
"ms-vscode.cpptools"
5+
],
6+
7+
"dockerFile": "Dockerfile"
8+
}

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
*.dwo
1818
*.do
1919
*.o
20+
*.o.tmp
2021
*.obj
2122
*.so
2223
*.dylib
@@ -29,3 +30,4 @@
2930

3031
/perf*
3132
.DS_Store
33+
.idea/*

CONTRIBUTING.md

+3-25
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ If you are already familiar with Julia itself, this blog post by Katharine Hyatt
66

77
## Learning Julia
88

9-
[The learning page](https://julialang.org/learning) has a great list of resources for new and experienced users alike. [This tutorial video](https://www.youtube.com/watch?v=vWkgEddb4-A) is one recommended starting point, as is the "[Invitation to Julia](https://www.youtube.com/watch?v=gQ1y5NUD_RI)" workshop video from JuliaCon 2015 ([slide materials here](https://github.com/dpsanders/invitation_to_julia)). The [Julia documentation](https://docs.julialang.org/en/latest) covers the language and core library features, and is searchable.
9+
[The learning page](https://julialang.org/learning) has a great list of resources for new and experienced users alike. [This tutorial video](https://www.youtube.com/watch?v=vWkgEddb4-A) is one recommended starting point, as is the "[Invitation to Julia](https://www.youtube.com/watch?v=gQ1y5NUD_RI)" workshop video from JuliaCon 2015 ([slide materials here](https://github.com/dpsanders/invitation_to_julia)). The [Julia documentation](https://docs.julialang.org) covers the language and core library features, and is searchable.
1010

1111
## Before filing an issue
1212

@@ -43,7 +43,7 @@ A useful bug report filed as a GitHub issue provides information about how to re
4343
- Try some simple debugging techniques to help isolate the problem.
4444
- Try running the code with the debug build of Julia with `make debug`, which produces the `usr/bin/julia-debug`.
4545
- Consider running `julia-debug` with a debugger such as `gdb` or `lldb`. Obtaining even a simple [backtrace](http://www.unknownroad.com/rtfm/gdbtut/gdbsegfault.html) is very useful.
46-
- If Julia segfaults, try following [these debugging tips](https://docs.julialang.org/en/latest/devdocs/backtraces#Reporting-and-analyzing-crashes-(segfaults)-1) to help track down the specific origin of the bug.
46+
- If Julia segfaults, try following [these debugging tips](https://docs.julialang.org/en/v1/devdocs/backtraces/) to help track down the specific origin of the bug.
4747

4848
2. If the problem is caused by a Julia package rather than core Julia, file a bug report with the relevant package author rather than here.
4949

@@ -56,28 +56,6 @@ A useful bug report filed as a GitHub issue provides information about how to re
5656

5757
## Submitting contributions
5858

59-
### Contributing a Julia package
60-
61-
Julia has a built-in [package manager](https://julialang.github.io/Pkg.jl/v1/) based on `git`. A number of [packages](https://pkg.julialang.org) across many domains are already available for Julia. Developers are encouraged to provide their libraries as a Julia package. The manual provides instructions on [creating Julia packages](https://julialang.github.io/Pkg.jl/v1/creating-packages/).
62-
63-
For developers who need to wrap C libraries so that they can be called from Julia, the [Clang.jl](https://github.com/ihnorton/Clang.jl) package can help generate the wrappers automatically from the C header files.
64-
65-
### Package Compatibility Across Releases
66-
67-
Sometimes, you might find that while your package works
68-
on the current release, it might not work on the upcoming release or nightly.
69-
This is due to the fact that some Julia functions (after some discussion)
70-
could be deprecated or removed altogether. This may cause your package to break or
71-
throw a number of deprecation warnings on usage. Therefore it is highly recommended
72-
to port your package to latest Julia release.
73-
74-
However, porting a package to the latest release may cause the package to break on
75-
earlier Julia releases. To maintain compatibility across releases, use
76-
[`Compat.jl`](https://github.com/JuliaLang/Compat.jl). Find the fix for your package
77-
from the README, and specify the minimum version of Compat that provides the fix
78-
in your REQUIRE file. To find the correct minimum version, refer to
79-
[this guide](https://github.com/JuliaLang/Compat.jl/#tagging-the-correct-minimum-version-of-compat).
80-
8159
### Writing tests
8260

8361
There are never enough tests. Track [code coverage at Coveralls](https://coveralls.io/r/JuliaLang/julia), and help improve it.
@@ -86,7 +64,7 @@ There are never enough tests. Track [code coverage at Coveralls](https://coveral
8664

8765
2. Browse through the source files and find some untested functionality (highlighted in red) that you think you might be able to write a test for.
8866

89-
3. Write a test that exercises this functionality---you can add your test to one of the existing files, or start a new one, whichever seems most appropriate to you. If you're adding a new test file, make sure you include it in the list of tests in `test/choosetests.jl`. https://docs.julialang.org/en/latest/stdlib/Test/ may be helpful in explaining how the testing infrastructure works.
67+
3. Write a test that exercises this functionality---you can add your test to one of the existing files, or start a new one, whichever seems most appropriate to you. If you're adding a new test file, make sure you include it in the list of tests in `test/choosetests.jl`. https://docs.julialang.org/en/v1/stdlib/Test/ may be helpful in explaining how the testing infrastructure works.
9068

9169
4. Run `make test-all` to rebuild Julia and run your new test(s). If you had to fix a bug or add functionality in `base`, this will ensure that your test passes and that you have not introduced extraneous whitespace.
9270

HISTORY.md

+130
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,131 @@
1+
Julia v1.4 Release Notes
2+
========================
3+
4+
New language features
5+
---------------------
6+
7+
* Structs with all isbits and isbitsunion fields are now stored inline in arrays ([#32448]).
8+
* `import` now allows quoted symbols, e.g. `import Base.:+` ([#33158]).
9+
* `a[begin]` can now be used to address the first element of an integer-indexed collection `a`.
10+
The index is computed by `firstindex(a)` ([#33946]).
11+
12+
Language changes
13+
----------------
14+
15+
* The syntax `(;)`, which used to parse as an empty block expression, is deprecated.
16+
In the future it will indicate an empty named tuple ([#30115]).
17+
18+
Multi-threading changes
19+
-----------------------
20+
21+
* Values can now be interpolated into `@async` and `@spawn` via `$`, which copies the value directly into the constructed
22+
underlying closure ([#33119]).
23+
24+
Build system changes
25+
--------------------
26+
27+
* Windows build installer has switched to Inno Setup. Installer command line parameters have thus changed. For example, to extract the installer to a specific directory, the command line parameter is now `/DIR=x:\dirname`. Use `julia-installer.exe /?` to list all new command line parameters.
28+
29+
New library functions
30+
---------------------
31+
32+
* The new `only(x)` function returns the one-and-only element of a collection `x`, and throws an `ArgumentError` if `x` contains zero or multiple elements ([#33129]).
33+
* `takewhile` and `dropwhile` have been added to the Iterators submodule ([#33437]).
34+
* `accumulate` has been added to the Iterators submodule ([#34033]).
35+
* There is a now an `evalpoly` function meant to take the role of the `@evalpoly` macro. The function is just as efficient as the macro while giving added flexibility, so it should be preferred over `@evalpoly`. `evalpoly` takes a list of coefficients as a tuple, so where one might write `@evalpoly(x, p1, p2, p3)` one would instead write `evalpoly(x, (p1, p2, p3))`.
36+
37+
New library features
38+
--------------------
39+
40+
* Function composition now supports multiple functions: `∘(f, g, h) = f ∘ g ∘ h`
41+
and splatting `∘(fs...)` for composing an iterable collection of functions ([#33568]).
42+
* Functions `gcd`, `lcm`, and `gcdx` now support `Rational` arguments ([#33910]).
43+
* The `splitpath` function now accepts any `AbstractString` whereas previously it only accepted paths of type `String` ([#33012]).
44+
* `filter` can now act on a `Tuple` ([#32968]).
45+
* The `tempname` function now takes an optional `parent::AbstractString` argument to give it a directory in which to attempt to produce a temporary path name ([#33090]).
46+
* The `tempname` function now takes a `cleanup::Bool` keyword argument defaulting to `true`, which causes the process to try to ensure that any file or directory at the path returned by `tempname` is deleted upon process exit ([#33090]).
47+
* The `readdir` function now takes a `join::Bool` keyword argument defaulting to `false`, which when set causes `readdir` to join its directory argument with each listed name ([#33113]).
48+
* `div` now accepts a rounding mode as the third argument, consistent with the corresponding argument to `rem`. Support for rounding division, by passing one of the RoundNearest modes to this function, was added. For future compatibility, library authors should now extend this function, rather than extending the two-argument `fld`/`cld`/`div` directly ([#33040]).
49+
* `methods` now accepts a module (or a list thereof) to filter methods defined in it ([#33403]).
50+
51+
Standard library changes
52+
------------------------
53+
54+
* Calling `show` or `repr` on an `undef`/`UndefInitializer()` array initializer now shows valid Julia code ([#33211]).
55+
* Calling `show` or `repr` on a 0-dimensional `AbstractArray` now shows valid code for creating an equivalent 0-dimensional array, instead of only showing the contained value ([#33206]).
56+
* `readdir` output is now guaranteed to be sorted. The `sort` keyword allows opting out of sorting to get names in OS-native order ([#33542]).
57+
* The methods of `mktemp` and `mktempdir` that take a function to pass temporary paths to no longer throw errors if the path is already deleted when the function returns ([#33091]).
58+
* Verbose `display` of `Char` (`text/plain` output) now shows the codepoint value in standard-conforming `"U+XXXX"` format ([#33291]).
59+
* `Iterators.partition` now uses views (or smartly re-computed ranges) for partitions of all `AbstractArray`s ([#33533]).
60+
* Sets are now displayed less compactly in the REPL, as a column of elements, like vectors
61+
and dictionaries ([#33300]).
62+
* `delete!` on `WeakKeyDict`s now returns the `WeakKeyDict` itself instead of the underlying `Dict` used for implementation
63+
64+
#### LinearAlgebra
65+
66+
* `qr` and `qr!` functions support `blocksize` keyword argument ([#33053]).
67+
* `dot` now admits a 3-argument method `dot(x, A, y)` to compute generalized dot products `dot(x, A*y)`, but without computing and storing the intermediate result `A*y` ([#32739]).
68+
* `ldlt` and non-pivoted `lu` now throw a new `ZeroPivotException` type ([#33372]).
69+
* `cond(A, p)` with `p=1` or `p=Inf` now computes the exact condition number instead of an estimate ([#33547]).
70+
* `UniformScaling` objects may now be exponentiated such that `(a*I)^x = a^x * I`.
71+
72+
#### Markdown
73+
74+
* Tables now have the `align` attribute set when `show`n as HTML ([#33849]).
75+
76+
#### Random
77+
78+
* `AbstractRNG`s now behave like scalars when used in broadcasting ([#33213]).
79+
* The performance of `rand(::Tuple)` is improved in some cases ([#32208]). As a consequence, the
80+
stream of generated values produced for a given seed has changed.
81+
82+
#### REPL
83+
84+
* The attributes of the implicit `IOContext` used by the REPL to display objects can be
85+
modified by the user (experimental feature) ([#29249]).
86+
87+
#### SparseArrays
88+
89+
* The return value of `zero(x::AbstractSparseArray)` has no stored zeros anymore ([#31835]).
90+
Previously, it would have stored zeros wherever `x` had them. This makes the operation
91+
constant time instead of `O(<number of stored values>)`.
92+
* Products involving sparse arrays now allow more general sparse `eltype`s, such as `StaticArrays` ([#33205])
93+
94+
<!--- generated by NEWS-update.jl: -->
95+
[#29249]: https://github.com/JuliaLang/julia/issues/29249
96+
[#30115]: https://github.com/JuliaLang/julia/issues/30115
97+
[#31835]: https://github.com/JuliaLang/julia/issues/31835
98+
[#32208]: https://github.com/JuliaLang/julia/issues/32208
99+
[#32448]: https://github.com/JuliaLang/julia/issues/32448
100+
[#32739]: https://github.com/JuliaLang/julia/issues/32739
101+
[#32968]: https://github.com/JuliaLang/julia/issues/32968
102+
[#33012]: https://github.com/JuliaLang/julia/issues/33012
103+
[#33040]: https://github.com/JuliaLang/julia/issues/33040
104+
[#33053]: https://github.com/JuliaLang/julia/issues/33053
105+
[#33090]: https://github.com/JuliaLang/julia/issues/33090
106+
[#33091]: https://github.com/JuliaLang/julia/issues/33091
107+
[#33113]: https://github.com/JuliaLang/julia/issues/33113
108+
[#33119]: https://github.com/JuliaLang/julia/issues/33119
109+
[#33129]: https://github.com/JuliaLang/julia/issues/33129
110+
[#33158]: https://github.com/JuliaLang/julia/issues/33158
111+
[#33205]: https://github.com/JuliaLang/julia/issues/33205
112+
[#33206]: https://github.com/JuliaLang/julia/issues/33206
113+
[#33211]: https://github.com/JuliaLang/julia/issues/33211
114+
[#33213]: https://github.com/JuliaLang/julia/issues/33213
115+
[#33291]: https://github.com/JuliaLang/julia/issues/33291
116+
[#33300]: https://github.com/JuliaLang/julia/issues/33300
117+
[#33372]: https://github.com/JuliaLang/julia/issues/33372
118+
[#33403]: https://github.com/JuliaLang/julia/issues/33403
119+
[#33437]: https://github.com/JuliaLang/julia/issues/33437
120+
[#33533]: https://github.com/JuliaLang/julia/issues/33533
121+
[#33542]: https://github.com/JuliaLang/julia/issues/33542
122+
[#33547]: https://github.com/JuliaLang/julia/issues/33547
123+
[#33568]: https://github.com/JuliaLang/julia/issues/33568
124+
[#33849]: https://github.com/JuliaLang/julia/issues/33849
125+
[#33910]: https://github.com/JuliaLang/julia/issues/33910
126+
[#33946]: https://github.com/JuliaLang/julia/issues/33946
127+
[#34033]: https://github.com/JuliaLang/julia/issues/34033
128+
1129
Julia v1.3 Release Notes
2130
========================
3131

@@ -46,6 +174,7 @@ New library functions
46174
Standard library changes
47175
------------------------
48176

177+
* `Pkg` won't clobber pre-compilation files as often when switching environments ([#32651])
49178
* `Pkg` can now download and install binary artifacts through the `Pkg.Artifacts`
50179
submodule and supporting functions. ([#32918])
51180
* When `wait` (or `@sync`, or `fetch`) is called on a failing `Task`, the exception is propagated as a
@@ -211,6 +340,7 @@ New library functions
211340
* Added `Base.hasproperty` and `Base.hasfield` ([#28850]).
212341
* One argument `!=(x)`, `>(x)`, `>=(x)`, `<(x)`, `<=(x)` have been added, returning partially-applied
213342
versions of the functions, similar to the existing `==(x)` and `isequal(x)` methods ([#30915]).
343+
* The new `map!(f, values(::AbstractDict))` method allows to modify in-place values of a dictionary ([#31223]).
214344

215345
Standard library changes
216346
------------------------

LICENSE.md

+2-6
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ Julia includes code from the following projects, which have their own licenses:
3535
- [MUSL](https://git.musl-libc.org/cgit/musl/tree/COPYRIGHT) (for getopt implementation on Windows) [MIT]
3636
- [MINGW](https://sourceforge.net/p/mingw/mingw-org-wsl/ci/legacy/tree/mingwrt/mingwex/dirname.c) (for dirname implementation on Windows) [MIT]
3737
- [NetBSD](https://www.netbsd.org/about/redistribution.html) (for setjmp, longjmp, and strptime implementations on Windows) [BSD-3]
38-
- [Python](https://docs.python.org/2/license.html) (for strtod and joinpath implementation on Windows) [BSD-3, effectively]
38+
- [Python](https://docs.python.org/3/license.html) (for strtod and joinpath implementation on Windows) [BSD-3, effectively]
39+
- [Google Benchmark](https://github.com/google/benchmark) (for cyclecount implementation) [Apache 2.0]
3940

4041
The following components included in Julia `Base` have their own separate licenses:
4142

@@ -52,11 +53,6 @@ own licenses:
5253
- [LLVM](https://releases.llvm.org/6.0.0/LICENSE.TXT) [BSD-3, effectively]
5354
- [UTF8PROC](https://github.com/JuliaStrings/utf8proc) [MIT]
5455

55-
The following components included in `stdlib` have their own separate licenses:
56-
57-
- stdlib/SuiteSparse/umfpack.jl (see [SUITESPARSE](http://suitesparse.com))
58-
- stdlib/SuiteSparse/cholmod.jl (see [SUITESPARSE](http://suitesparse.com))
59-
6056
Julia's `stdlib` uses the following external libraries, which have their own licenses:
6157

6258
- [DSFMT](http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/SFMT/LICENSE.txt) [BSD-3]

0 commit comments

Comments
 (0)