File tree 1 file changed +4
-1
lines changed
compiler/src/dotty/tools/dotc/sbt
1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -152,7 +152,9 @@ private class ExtractAPICollector(using Context) extends ThunkHolder {
152
152
*/
153
153
private val seenInlineCache = mutable.HashSet .empty[Symbol ]
154
154
155
- /** This cache is optional, it avoids recomputing hashes of inline "Body" annotations. */
155
+ /** This cache is optional, it avoids recomputing hashes of inline "Body" annotations,
156
+ * e.g. when a concrete inline method is inherited by a subclass.
157
+ */
156
158
private val inlineBodyCache = mutable.HashMap .empty[Symbol , Int ]
157
159
158
160
private val allNonLocalClassesInSrc = new mutable.HashSet [xsbti.api.ClassLike ]
@@ -658,6 +660,7 @@ private class ExtractAPICollector(using Context) extends ThunkHolder {
658
660
// FIXME: The API of a class we send to Zinc includes the signatures of
659
661
// inherited methods, which means that we repeatedly compute the hash of
660
662
// an inline def in every class that extends its owner. To avoid this we
663
+ // currently cache it in `inlineBodyCache`. Alternatively, we
661
664
// could store the hash as an annotation when pickling an inline def
662
665
// and retrieve it here instead of computing it on the fly.
663
666
You can’t perform that action at this time.
0 commit comments