Skip to content

Commit d0e71a2

Browse files
committed
Rename global cache to stable cache
1 parent 9ea3624 commit d0e71a2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

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

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -277,17 +277,17 @@ object Semantic {
277277
class Cache {
278278
private val in: CacheStore = mutable.Map.empty
279279
private var out: CacheStore = mutable.Map.empty
280-
private val global: CacheStore = mutable.Map.empty
280+
private val stable: CacheStore = mutable.Map.empty
281281
private var changed: Boolean = false
282282

283283
def hasChanged = changed
284284

285285
def contains(value: Value, expr: Tree) =
286-
out.contains(value, expr) || global.contains(value, expr)
286+
out.contains(value, expr) || stable.contains(value, expr)
287287

288288
def apply(value: Value, expr: Tree) =
289289
if out.contains(value, expr) then out(value)(expr)
290-
else global(value)(expr)
290+
else stable(value)(expr)
291291

292292
def assume(value: Value, expr: Tree) =
293293

@@ -310,7 +310,7 @@ object Semantic {
310310

311311
/** Prepare cache for the next iteration
312312
*
313-
* - Commit out cache to global cache if unchanged.
313+
* - Commit out cache to stable cache if unchanged.
314314
* - Reset changed flag
315315
* - Reset out cache
316316
*
@@ -320,7 +320,7 @@ object Semantic {
320320
if !changed then
321321
out.foreach { (v, m) =>
322322
m.iterator.foreach { (e, res) =>
323-
global.put(v, e, res)
323+
stable.put(v, e, res)
324324
}
325325
}
326326
end if

0 commit comments

Comments
 (0)