@@ -1580,15 +1580,21 @@ end
15801580f_typeof_tfunc (x) = typeof (x)
15811581@test Base. return_types (f_typeof_tfunc, (Union{<: T , Int} where T<: Complex ,)) == Any[Union{Type{Int}, Type{Complex{T}} where T<: Real }]
15821582
1583- # memoryref_tfunc, memoryrefget_tfunc, memoryrefset!_tfunc
1583+ # memoryref_tfunc, memoryrefget_tfunc, memoryrefset!_tfunc, memoryref_isassigned, memoryrefoffset_tfunc
15841584let memoryref_tfunc (@nospecialize xs... ) = Core. Compiler. memoryref_tfunc (Core. Compiler. fallback_lattice, xs... )
15851585 memoryrefget_tfunc (@nospecialize xs... ) = Core. Compiler. memoryrefget_tfunc (Core. Compiler. fallback_lattice, xs... )
1586+ memoryref_isassigned_tfunc (@nospecialize xs... ) = Core. Compiler. memoryref_isassigned_tfunc (Core. Compiler. fallback_lattice, xs... )
15861587 memoryrefset!_tfunc (@nospecialize xs... ) = Core. Compiler. memoryrefset!_tfunc (Core. Compiler. fallback_lattice, xs... )
1588+ memoryrefoffset_tfunc (@nospecialize xs... ) = Core. Compiler. memoryrefoffset_tfunc (Core. Compiler. fallback_lattice, xs... )
1589+ interp = Core. Compiler. NativeInterpreter ()
1590+ builtin_tfunction (@nospecialize xs... ) = Core. Compiler. builtin_tfunction (interp, xs... , nothing )
15871591 @test memoryref_tfunc (Memory{Int}) == MemoryRef{Int}
15881592 @test memoryref_tfunc (Memory{Integer}) == MemoryRef{Integer}
15891593 @test memoryref_tfunc (MemoryRef{Int}, Int) == MemoryRef{Int}
1594+ @test memoryref_tfunc (MemoryRef{Int}, Vararg{Int}) == MemoryRef{Int}
15901595 @test memoryref_tfunc (MemoryRef{Int}, Int, Symbol) == Union{}
15911596 @test memoryref_tfunc (MemoryRef{Int}, Int, Bool) == MemoryRef{Int}
1597+ @test memoryref_tfunc (MemoryRef{Int}, Int, Vararg{Bool}) == MemoryRef{Int}
15921598 @test memoryref_tfunc (Memory{Int}, Int) == Union{}
15931599 @test memoryref_tfunc (Any, Any, Any) == Any # also probably could be GenericMemoryRef
15941600 @test memoryref_tfunc (Any, Any) == Any # also probably could be GenericMemoryRef
@@ -1603,6 +1609,20 @@ let memoryref_tfunc(@nospecialize xs...) = Core.Compiler.memoryref_tfunc(Core.Co
16031609 @test memoryrefget_tfunc (MemoryRef{Int}, String, Bool) === Union{}
16041610 @test memoryrefget_tfunc (MemoryRef{Int}, Symbol, String) === Union{}
16051611 @test memoryrefget_tfunc (Any, Any, Any) === Any
1612+ @test builtin_tfunction (Core. memoryrefget, Any[MemoryRef{Int}, Vararg{Any}]) == Int
1613+ @test builtin_tfunction (Core. memoryrefget, Any[MemoryRef{Int}, Symbol, Bool, Vararg{Bool}]) == Int
1614+ @test memoryref_isassigned_tfunc (MemoryRef{Any}, Symbol, Bool) === Bool
1615+ @test memoryref_isassigned_tfunc (MemoryRef{Any}, Any, Any) === Bool
1616+ @test memoryref_isassigned_tfunc (MemoryRef{<: Integer }, Symbol, Bool) === Bool
1617+ @test memoryref_isassigned_tfunc (GenericMemoryRef, Symbol, Bool) === Bool
1618+ @test memoryref_isassigned_tfunc (GenericMemoryRef{:not_atomic }, Symbol, Bool) === Bool
1619+ @test memoryref_isassigned_tfunc (Vector{Int}, Symbol, Bool) === Union{}
1620+ @test memoryref_isassigned_tfunc (String, Symbol, Bool) === Union{}
1621+ @test memoryref_isassigned_tfunc (MemoryRef{Int}, String, Bool) === Union{}
1622+ @test memoryref_isassigned_tfunc (MemoryRef{Int}, Symbol, String) === Union{}
1623+ @test memoryref_isassigned_tfunc (Any, Any, Any) === Bool
1624+ @test builtin_tfunction (Core. memoryref_isassigned, Any[MemoryRef{Int}, Vararg{Any}]) == Bool
1625+ @test builtin_tfunction (Core. memoryref_isassigned, Any[MemoryRef{Int}, Symbol, Bool, Vararg{Bool}]) == Bool
16061626 @test memoryrefset!_tfunc (MemoryRef{Int}, Int, Symbol, Bool) === MemoryRef{Int}
16071627 let ua = MemoryRef{<: Integer }
16081628 @test memoryrefset!_tfunc (ua, Int, Symbol, Bool) === ua
@@ -1617,6 +1637,15 @@ let memoryref_tfunc(@nospecialize xs...) = Core.Compiler.memoryref_tfunc(Core.Co
16171637 @test memoryrefset!_tfunc (GenericMemoryRef{:not_atomic }, Any, Any, Any) === GenericMemoryRef{:not_atomic }
16181638 @test memoryrefset!_tfunc (GenericMemoryRef, Any, Any, Any) === GenericMemoryRef
16191639 @test memoryrefset!_tfunc (Any, Any, Any, Any) === Any # also probably could be GenericMemoryRef
1640+ @test builtin_tfunction (Core. memoryrefset!, Any[MemoryRef{Int}, Vararg{Any}]) == MemoryRef{Int}
1641+ @test builtin_tfunction (Core. memoryrefset!, Any[MemoryRef{Int}, Vararg{Symbol}]) == Union{}
1642+ @test builtin_tfunction (Core. memoryrefset!, Any[MemoryRef{Int}, Any, Symbol, Vararg{Bool}]) == MemoryRef{Int}
1643+ @test builtin_tfunction (Core. memoryrefset!, Any[MemoryRef{Int}, Any, Symbol, Bool, Vararg{Any}]) == MemoryRef{Int}
1644+ @test memoryrefoffset_tfunc (MemoryRef) == memoryrefoffset_tfunc (GenericMemoryRef) == Int
1645+ @test memoryrefoffset_tfunc (Memory) == memoryrefoffset_tfunc (GenericMemory) == Union{}
1646+ @test builtin_tfunction (Core. memoryrefoffset, Any[Vararg{MemoryRef}]) == Int
1647+ @test builtin_tfunction (Core. memoryrefoffset, Any[Vararg{Any}]) == Int
1648+ @test builtin_tfunction (Core. memoryrefoffset, Any[Vararg{Memory}]) == Union{}
16201649end
16211650
16221651let tuple_tfunc (@nospecialize xs... ) =
0 commit comments