File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -48,14 +48,9 @@ wrapped by `x`, such that mutating `extern(x)` might mutate `x` itself.
48
48
abstract type AbstractWirtinger <: AbstractDifferential end
49
49
50
50
unwrap_wirtinger (x) = x
51
- unwrap_wirtinger (x:: Union{Casted,AbstractThunk} ) = unwrap_wirtinger (extern (x))
52
51
53
52
wirtinger_primal (x) = x
54
- wirtinger_primal (x:: Union{Casted,AbstractThunk} ) =
55
- throw (ArgumentError (" `wirtinger_primal` is not defined for $(typeof (x)) . Call `unwrap_wirtinger` first" )
56
53
wirtinger_conjugate (:: Any ) = Zero ()
57
- wirtinger_primal (x:: Union{Casted,AbstractThunk} ) =
58
- throw (ArgumentError (" `wirtinger_conjugate` is not defined for $(typeof (x)) . Call `unwrap_wirtinger` first" )
59
54
60
55
extern (x:: AbstractWirtinger ) = throw (ArgumentError (" `AbstractWirtinger` cannot be converted to an external type." ))
61
56
214
209
return element, (externed, new_state)
215
210
end
216
211
212
+ unwrap_wirtinger (x:: Union{Casted,AbstractThunk} ) = unwrap_wirtinger (extern (x))
213
+
214
+ wirtinger_primal (x:: Union{Casted,AbstractThunk} ) =
215
+ throw (ArgumentError (" `wirtinger_primal` is not defined for $(typeof (x)) . Call `unwrap_wirtinger` first" ))
216
+ wirtinger_primal (x:: Union{Casted,AbstractThunk} ) =
217
+ throw (ArgumentError (" `wirtinger_conjugate` is not defined for $(typeof (x)) . Call `unwrap_wirtinger` first" ))
218
+
217
219
# ####
218
220
# #### `Thunk`
219
221
# ####
You can’t perform that action at this time.
0 commit comments