Skip to content

Commit c294a9a

Browse files
Update support for timing internals (#608)
* update support for timing internals * bump JuliaInterpreter compat * Patch bump
1 parent f13e0a4 commit c294a9a

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

Project.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "ChainRules"
22
uuid = "082447d4-558c-5d27-93f4-14fc19e9eca2"
3-
version = "1.28.1"
3+
version = "1.28.2"
44

55
[deps]
66
ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"
@@ -18,7 +18,7 @@ ChainRulesTestUtils = "1.5"
1818
Compat = "3.42.0"
1919
FiniteDifferences = "0.12.20"
2020
IrrationalConstants = "0.1.1"
21-
JuliaInterpreter = "0.8" # latest is "0.9.1"
21+
JuliaInterpreter = "0.8,0.9"
2222
RealDot = "0.1"
2323
StaticArrays = "1.2"
2424
julia = "1.6"

src/rulesets/Base/nondiff.jl

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -453,8 +453,12 @@ end
453453
@non_differentiable Base.time_ns()
454454
@non_differentiable Base.typename(::Any)
455455
@non_differentiable Base.depwarn(::Any...)
456-
@non_differentiable Base.cumulative_compile_time_ns_before()
457-
@non_differentiable Base.cumulative_compile_time_ns_after()
456+
if isdefined(Base, :cumulative_compile_time_ns_before)
457+
@non_differentiable Base.cumulative_compile_time_ns_before()
458+
@non_differentiable Base.cumulative_compile_time_ns_after()
459+
elseif isdefined(Base, :cumulative_compile_time_ns)
460+
@non_differentiable Base.cumulative_compile_time_ns()
461+
end
458462
@non_differentiable Base.time_print(::Any...)
459463

460464
@non_differentiable Broadcast.combine_styles(::Any...)

0 commit comments

Comments
 (0)