Skip to content

Commit d6629e8

Browse files
liufengyunq-ata
andauthored
Apply suggestions from code review
Co-authored-by: q-ata <[email protected]>
1 parent 624dc40 commit d6629e8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

compiler/src/dotty/tools/dotc/transform/init/Objects.scala

+3-3
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ object Objects:
100100

101101
def initVal(field: Symbol, value: Value)(using Context) = log("Initialize " + field.show + " = " + value + " for " + this, printer) {
102102
assert(!field.is(Flags.Mutable), "Field is mutable: " + field.show)
103-
assert(!vals.contains(field), "Field already set " + field.show)
103+
assert(!vals.contains(field), "Field already set: " + field.show)
104104
vals(field) = value
105105
}
106106

@@ -111,7 +111,7 @@ object Objects:
111111
}
112112

113113
def initOuter(cls: ClassSymbol, value: Value)(using Context) = log("Initialize outer " + cls.show + " = " + value + " for " + this, printer) {
114-
assert(!outers.contains(cls), "Outer already set " + cls)
114+
assert(!outers.contains(cls), "Outer already set: " + cls)
115115
outers(cls) = value
116116
}
117117

@@ -1355,7 +1355,7 @@ object Objects:
13551355
* @param klass The enclosing class where the type `C.this` is located.
13561356
* @param elideObjectAccess Whether object access should be omitted.
13571357
*
1358-
* Object access elission happens when the object access is used as a prefix
1358+
* Object access elision happens when the object access is used as a prefix
13591359
* in `new o.C` and `C` does not need an outer.
13601360
*/
13611361
def resolveThis(target: ClassSymbol, thisV: Value, klass: ClassSymbol, elideObjectAccess: Boolean = false): Contextual[Value] = log("resolveThis target = " + target.show + ", this = " + thisV.show, printer, (_: Value).show) {

0 commit comments

Comments
 (0)