parent
b11ff518fa
commit
bc42e9aa98
2 changed files with 11 additions and 0 deletions
10
tests/exception/tcpp_imported_exc2.nim
Normal file
10
tests/exception/tcpp_imported_exc2.nim
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
discard """
|
||||
targets: "cpp"
|
||||
output: ""
|
||||
"""
|
||||
#issue #14369 case 2
|
||||
type RuntimeError {.requiresInit, importcpp: "std::runtime_error", header: "<stdexcept>".} = object
|
||||
|
||||
proc initRuntimeError(a: cstring): RuntimeError {.importcpp: "std::runtime_error(@)", constructor.}
|
||||
try: raise initRuntimeError("foo2")
|
||||
except: discard
|
||||
Loading…
Add table
Add a link
Reference in a new issue