aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/SymDenotations.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-02-26 11:01:02 +0100
committerMartin Odersky <odersky@gmail.com>2014-02-26 11:03:33 +0100
commit32c041c8b40df3007783240493ed4c4708ec80db (patch)
treecc3a72cee58a4b8cdeb50674d8120fde0a3ebf66 /src/dotty/tools/dotc/core/SymDenotations.scala
parent311136b60d2de17f46b643d84a949b8f77411c0f (diff)
downloaddotty-32c041c8b40df3007783240493ed4c4708ec80db.tar.gz
dotty-32c041c8b40df3007783240493ed4c4708ec80db.tar.bz2
dotty-32c041c8b40df3007783240493ed4c4708ec80db.zip
Performance tweak: Denotation.symbol is a parameter.
This avoids the megamorphic dispatch on symbol before. Looked promising in the profiler (symbol showed up at 9%) but does not seem to gain much in practice. Still, can't hurt to do it.
Diffstat (limited to 'src/dotty/tools/dotc/core/SymDenotations.scala')
-rw-r--r--src/dotty/tools/dotc/core/SymDenotations.scala4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/dotty/tools/dotc/core/SymDenotations.scala b/src/dotty/tools/dotc/core/SymDenotations.scala
index 9ae5efb89..a867253b7 100644
--- a/src/dotty/tools/dotc/core/SymDenotations.scala
+++ b/src/dotty/tools/dotc/core/SymDenotations.scala
@@ -60,12 +60,12 @@ object SymDenotations {
* during a period.
*/
class SymDenotation private[SymDenotations] (
- final val symbol: Symbol,
+ symbol: Symbol,
ownerIfExists: Symbol,
final val name: Name,
initFlags: FlagSet,
initInfo: Type,
- initPrivateWithin: Symbol = NoSymbol) extends SingleDenotation {
+ initPrivateWithin: Symbol = NoSymbol) extends SingleDenotation(symbol) {
//assert(symbol.id != 4940, name)