aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/NameOps.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2016-09-01 11:59:13 +0200
committerMartin Odersky <odersky@gmail.com>2016-10-02 16:07:00 +0200
commitc87a9dd1f34cd7afe3fba0edfa1463019eaa78bd (patch)
tree7500f567d08b96ccbf3a26dd02b76c0ca42aadda /src/dotty/tools/dotc/core/NameOps.scala
parent56f01cdf9081b0b221a01e5ae1a9f10e4aa62da9 (diff)
downloaddotty-c87a9dd1f34cd7afe3fba0edfa1463019eaa78bd.tar.gz
dotty-c87a9dd1f34cd7afe3fba0edfa1463019eaa78bd.tar.bz2
dotty-c87a9dd1f34cd7afe3fba0edfa1463019eaa78bd.zip
First version of inline scheme
To be done: outer accessors To be done: error positions
Diffstat (limited to 'src/dotty/tools/dotc/core/NameOps.scala')
-rw-r--r--src/dotty/tools/dotc/core/NameOps.scala2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/core/NameOps.scala b/src/dotty/tools/dotc/core/NameOps.scala
index f5e0eb8cd..ea255e5b3 100644
--- a/src/dotty/tools/dotc/core/NameOps.scala
+++ b/src/dotty/tools/dotc/core/NameOps.scala
@@ -166,7 +166,7 @@ object NameOps {
// Hack to make super accessors from traits work. They would otherwise fail because of #765
// TODO: drop this once we have more robust name handling
- if (name.slice(idx - FalseSuperLength, idx) == FalseSuper)
+ if (idx > FalseSuperLength && name.slice(idx - FalseSuperLength, idx) == FalseSuper)
idx -= FalseSuper.length
if (idx < 0) name else (name drop (idx + nme.EXPAND_SEPARATOR.length)).asInstanceOf[N]