aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/pickling/TreeBuffer.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/dotty/tools/dotc/core/pickling/TreeBuffer.scala')
-rw-r--r--src/dotty/tools/dotc/core/pickling/TreeBuffer.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/core/pickling/TreeBuffer.scala b/src/dotty/tools/dotc/core/pickling/TreeBuffer.scala
index 5a445124d..73b944b92 100644
--- a/src/dotty/tools/dotc/core/pickling/TreeBuffer.scala
+++ b/src/dotty/tools/dotc/core/pickling/TreeBuffer.scala
@@ -46,7 +46,7 @@ class TreeBuffer extends TastyBuffer(1000000) {
}
def adjusted(x: Addr): Addr = {
- val idx = bestFit(offsets, x.index - 1)
+ val idx = bestFit(offsets, numOffsets, x.index - 1)
if (idx < 0) x else x - delta(idx)
}