Skip to content

Commit b5eb8c4

Browse files
committed
Document message identity in debugging.md
Addresses #1931
1 parent 113e034 commit b5eb8c4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docs/topics/debugging.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,9 @@ Exception copy logic is straightforward:
6363
1) If the exception class implements [CopyableThrowable], [CopyableThrowable.createCopy] is used.
6464
`null` can be returned from `createCopy` to opt-out specific exception from being recovered.
6565
2) If the exception class has class-specific fields not inherited from Throwable, the exception is not copied.
66-
3) Otherwise, one of the public exception's constructor is invoked reflectively with an optional `initCause` call.
66+
3) Otherwise, one of the public exception's constructor is invoked reflectively with an optional `initCause` call.
67+
4) If the reflective copy has a changed message (exception class modifies 'message' parameter before passing it to the superclass),
68+
the exception is not copied in order to preserve a human-readable message. [CopyableThrowable] does not have such limitation.
6769

6870
## Debug agent
6971

0 commit comments

Comments
 (0)