The explanation should provide a detailed description of why the error occurred and use examples from the user's own code to illustrate how to avoid these errors.
The kind of the error message is something like "Syntax" or "Type Mismatch"
The msg
contains the diagnostic message e.g:
The msg
contains the diagnostic message e.g:
> expected: String > found: Int
This message will be placed underneath the position given by the enclosing
MessageContainer
a unique number identifying the message, this will later be used to reference documentation online
The implicit Context
in messages is a large thing that we don't want
persisted.
The implicit Context
in messages is a large thing that we don't want
persisted. This method gets around that by duplicating the message
without the implicit context being passed along.
A
Message
contains all semantic information necessary to easily comprehend what caused the message to be logged. Each message can be turned into aMessageContainer
which contains the log level and can later be consumed by a subclass ofReporter
. However, the error position is only part ofMessageContainer
, notMessage
.NOTE: you should not be persisting messages. Most messages take an implicit
Context
and these contexts weigh in at about 4mb per instance, as such persisting these will result in a memory leak.Instead use the
persist
method to create an instance that does not keep a reference to these contexts.