We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
get_cache_key
1 parent e09d5b4 commit 9d625d8Copy full SHA for 9d625d8
src/cache.jl
@@ -26,7 +26,20 @@ The key stored in the cache for a particular value. Returns a `SymbolicKey` for
26
"""
27
# can't dispatch because `BasicSymbolic` isn't defined here
28
function get_cache_key(x)
29
- if x isa BasicSymbolic
+ @nospecialize x
30
+ if x isa BasicSymbolic{SymReal}
31
+ id = x.id
32
+ if id === nothing
33
+ return CacheSentinel()
34
+ end
35
+ return SymbolicKey(id)
36
+ elseif x isa BasicSymbolic{SafeReal}
37
38
39
40
41
42
43
id = x.id
44
if id === nothing
45
return CacheSentinel()
0 commit comments