File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ struct FunctionUnimplementedError <: Exception
2+ type:: String
3+ end
4+
5+ function Base. showerror (io:: IO , err:: FunctionUnimplementedError )
6+ print (io, " The $(err. type) version for this function is invalid" )
7+ end
8+
19function get_unimplemented_fn (nargs, type)
210 expr = :(function unimplemented ()
3- error ( " The $ ($ type) version for this function is invalid " )
11+ throw ( $ FunctionUnimplementedError ($ type))
412 end )
513
614 for i in 1 : nargs
Original file line number Diff line number Diff line change 6868 out_2 = similar (out_1)
6969 h_ip! (out_1, inputs... )
7070 h_julia! (out_2, inputs... )
71- @test_throws ErrorException h3_oop (inputs... )
71+ @test_throws Symbolics . FunctionUnimplementedError h3_oop (inputs... )
7272 @test out_1 == out_2
7373 h3_ip (out_1, inputs... )
7474 @test out_1 == out_2
75- @test_throws ErrorException h4_ip (out_1, inputs... )
75+ @test_throws Symbolics . FunctionUnimplementedError h4_ip (out_1, inputs... )
7676 @test h4_oop (inputs... ) == h_julia (inputs... )
7777 out_1 = similar (h, Int)
7878 fill! (out_1, 10 )
You can’t perform that action at this time.
0 commit comments