diff --git a/compiler/src/dotty/tools/dotc/core/SymDenotations.scala b/compiler/src/dotty/tools/dotc/core/SymDenotations.scala index 44e9d162d8a6..010dc3ea011a 100644 --- a/compiler/src/dotty/tools/dotc/core/SymDenotations.scala +++ b/compiler/src/dotty/tools/dotc/core/SymDenotations.scala @@ -733,10 +733,10 @@ object SymDenotations { originalName.isSetterName && (!isCompleted || info.firstParamTypes.nonEmpty) // to avoid being fooled by var x_= : Unit = ... - /** is this a symbol representing an import? */ + /** Is this a symbol representing an import? */ final def isImport: Boolean = name == nme.IMPORT - /** is this the constructor of a class? */ + /** Is this the constructor of a class? */ final def isClassConstructor: Boolean = name == nme.CONSTRUCTOR /** Is this the constructor of a trait or a class */ diff --git a/library/src/scala/tasty/Reflection.scala b/library/src/scala/tasty/Reflection.scala index 7c7762cb04ca..d4ae7295c8ee 100644 --- a/library/src/scala/tasty/Reflection.scala +++ b/library/src/scala/tasty/Reflection.scala @@ -2679,14 +2679,30 @@ trait Reflection { reflection => /** Annotations attached to this symbol */ def annots: List[Term] + /** Does this symbol come from a currently compiled source file? */ def isDefinedInCurrentRun: Boolean + /** Dummy val symbol that owns all statements within the initialization of the class. + * This may also contain local definitions such as classes defined in a `locally` block in the class. + */ def isLocalDummy: Boolean + + /** Is this symbol a class representing a refinement? */ def isRefinementClass: Boolean + + /** Is this symbol an alias type? */ def isAliasType: Boolean + + /** Is this symbol an anonymous class? */ def isAnonymousClass: Boolean + + /** Is this symbol an anonymous function? */ def isAnonymousFunction: Boolean + + /** Is this symbol an abstract type? */ def isAbstractType: Boolean + + /** Is this the constructor of a class? */ def isClassConstructor: Boolean /** Is this the definition of a type? */