File tree Expand file tree Collapse file tree 2 files changed +7
-7
lines changed
compiler/src/dotty/tools/dotc Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -24,9 +24,9 @@ object Message {
2424 * consumed by a subclass of `Reporter`. However, the error position is only
2525 * part of `Diagnostic`, not `Message`.
2626 *
27- * NOTE: you should not be persisting Most messages take an implicit
28- * `Context` and these contexts weigh in at about 4mb per instance, as such
29- * persisting these will result in a memory leak.
27+ * NOTE: you should not persist a message directly, because most messages take
28+ * an implicit `Context` and these contexts weigh in at about 4mb per instance.
29+ * Therefore, persisting these will result in a memory leak.
3030 *
3131 * Instead use the `persist` method to create an instance that does not keep a
3232 * reference to these contexts.
Original file line number Diff line number Diff line change @@ -5,9 +5,9 @@ import language.implicitConversions
55/** The offsets part of a full position, consisting of 2 or 3 entries:
66 * - start: the start offset of the span, in characters from start of file
77 * - end : the end offset of the span
8- * - point: if given, the offset where a sing;le `^` would be logically placed
8+ * - point: if given, the offset where a single `^` would be logically placed
99 *
10- & Spans are encoded according to the following format in little endian:
10+ * Spans are encoded according to the following format in little endian:
1111 * Start: unsigned 26 Bits (works for source files up to 64M)
1212 * End: unsigned 26 Bits
1313 * Point: unsigned 12 Bits relative to start
@@ -30,8 +30,8 @@ object Spans {
3030
3131 /** A span indicates a range between a start offset and an end offset.
3232 * Spans can be synthetic or source-derived. A source-derived span
33- * has in addition a point lies somewhere between start and end. The point
34- * is roughly where the ^ would go if an error was diagnosed at that position.
33+ * has in addition a point. The point lies somewhere between start and end. The point
34+ * is roughly where the `^` would go if an error was diagnosed at that position.
3535 * All quantities are encoded opaquely in a Long.
3636 */
3737 class Span (val coords : Long ) extends AnyVal {
You can’t perform that action at this time.
0 commit comments