Skip to content

Commit 71cd556

Browse files
KenoKristofferC
authored andcommitted
Add missing latestworld after parameterized type alias (#57299)
Fixes #57267 (cherry picked from commit e553fc8)
1 parent 8b64d37 commit 71cd556

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

src/julia-syntax.scm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1480,6 +1480,7 @@
14801480
`(block
14811481
(= ,rr (where ,type-ex ,@params))
14821482
(,(if allow-local 'assign-const-if-global 'const) ,name ,rr)
1483+
(latestworld-if-toplevel)
14831484
,rr)))
14841485
(expand-forms
14851486
`(const (= ,name ,type-ex)))))

test/syntax.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4050,3 +4050,10 @@ end
40504050
import ..Base
40514051
using .Base: zero, zero
40524052
end
4053+
4054+
# #57267 - Missing `latestworld` after typealias
4055+
abstract type A57267{S, T} end
4056+
@test_nowarn @eval begin
4057+
B57267{S} = A57267{S, 1}
4058+
const C57267 = B57267
4059+
end

0 commit comments

Comments
 (0)