Skip to content

Commit

Permalink
Put uses of @pure and @_pure_meta behind @static if
Browse files Browse the repository at this point in the history
  • Loading branch information
martinholters committed Feb 18, 2023
1 parent 034a421 commit ffd1e1a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "Compat"
uuid = "34da2185-b29b-5c13-b0c7-acf172513d20"
version = "3.46.0"
version = "3.46.1"

[deps]
Base64 = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f"
Expand Down
4 changes: 2 additions & 2 deletions src/Compat.jl
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ if VERSION < v"1.1.0-DEV.506"
end

# https://github.com/JuliaLang/julia/pull/30496
if VERSION < v"1.2.0-DEV.272"
@static if VERSION < v"1.2.0-DEV.272"
Base.@pure hasfield(::Type{T}, name::Symbol) where T =
Base.fieldindex(T, name, false) > 0
export hasfield
Expand Down Expand Up @@ -277,7 +277,7 @@ if VERSION < v"1.4.0-DEV.551"
end

# https://github.com/JuliaLang/julia/pull/34652
if VERSION < v"1.5.0-DEV.247"
@static if VERSION < v"1.5.0-DEV.247"
export ismutable
ismutable(@nospecialize(x)) = (Base.@_pure_meta; typeof(x).mutable)
end
Expand Down

0 comments on commit ffd1e1a

Please sign in to comment.