Summary
When using ToDiagnostic() in verse to debug values when working with verse, if we do any operations with the diagnostic values, such as addition with strings, concatenation with other diagnostics and so on, it breaks and does not output anything on the logs.
Please select what you are reporting on:
Verse
What Type of Bug are you experiencing?
Verse
Steps to Reproduce
- Try to Print a diagnostic value that were formatted, example:
DiagnosticToPrint : diagnostic = "[DEBUG TEST] " + ToDiagnostic(SomeClass) + "\n\t" + "Value: " + ToDiagnostic(SomeClass.MyVariable)
Print(DiagnosticToPrint) # Silently fails, no error, but also no message printed on the logs at all (not even a blank message)
(Note: The strings and values being concatenated on the diagnostic above are just examples, the bug happens with anything, not only with these specific characters/usage)
Expected Result
The resulting diagnostic after the concatenation should be currectly formatted and printed on the logs
Observed Result
Nothing prints when using a concatenated diagnostic, not even a blank message entry on the logs - it just gets “ignored” entirely.
Platform(s)
All
Additional Notes
This issue only happens with concatenated diagnostics, it does not happen with singular ones, for example:
Test1 : diagnostic = ToDiagnostic(MyClass) # works
Test2 : diagnostic = ToDiagnostic(MyClass) + ToDiagnostic(OtherClass) # broken
Test3 : diagnostic = "ClassDebug: " + ToDiagnostic(MyClass) # broken
# Same if we convert the string to diagnostic first:
Test4 : diagnostic = ToDiagnostic("ClassDebug: ") + ToDiagnostic(MyClass) # broken