aboutsummaryrefslogtreecommitdiffstats
path: root/docs/topics/debugging.md
diff options
context:
space:
mode:
Diffstat (limited to 'docs/topics/debugging.md')
-rw-r--r--docs/topics/debugging.md5
1 files changed, 4 insertions, 1 deletions
diff --git a/docs/topics/debugging.md b/docs/topics/debugging.md
index d18df7f4..5ff4d549 100644
--- a/docs/topics/debugging.md
+++ b/docs/topics/debugging.md
@@ -63,7 +63,10 @@ Exception copy logic is straightforward:
1) If the exception class implements [CopyableThrowable], [CopyableThrowable.createCopy] is used.
`null` can be returned from `createCopy` to opt-out specific exception from being recovered.
2) If the exception class has class-specific fields not inherited from Throwable, the exception is not copied.
- 3) Otherwise, one of the public exception's constructor is invoked reflectively with an optional `initCause` call.
+ 3) Otherwise, one of the public exception's constructor is invoked reflectively with an optional `initCause` call.
+ 4) If the reflective copy has a changed message (exception constructor passed a modified `message` parameter to the superclass),
+ the exception is not copied in order to preserve a human-readable message. [CopyableThrowable] does not have such a limitation
+ and allows the copy to have a `message` different from that of the original.
## Debug agent