aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/DenotTransformers.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/dotty/tools/dotc/core/DenotTransformers.scala')
-rw-r--r--src/dotty/tools/dotc/core/DenotTransformers.scala8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/dotty/tools/dotc/core/DenotTransformers.scala b/src/dotty/tools/dotc/core/DenotTransformers.scala
index 6daa028fc..e052a07ea 100644
--- a/src/dotty/tools/dotc/core/DenotTransformers.scala
+++ b/src/dotty/tools/dotc/core/DenotTransformers.scala
@@ -46,4 +46,12 @@ object DenotTransformers {
}
}
}
+
+ /** A `DenotTransformer` trait that has the identity as its `transform` method.
+ * You might want to inherit from this trait so that new denotations can be
+ * installed using `installAfter` and `enteredAfter` at the end of the phase.
+ */
+ trait IdentityDenotTransformer extends DenotTransformer {
+ def transform(ref: SingleDenotation)(implicit ctx: Context): SingleDenotation = ref
+ }
}