File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
compiler/src/dotty/tools/dotc/typer
tests/pos-special/fatal-warnings Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -905,12 +905,12 @@ object RefChecks {
905
905
owner.isDeprecated
906
906
|| isEnumOwner(owner)
907
907
908
- def isDeprecatedOrSyntheticMethod (owner : Symbol ) = owner.isDeprecated || owner.isAllOf( Method & Synthetic )
908
+ def isDeprecatedOrSyntheticMethod (owner : Symbol ) = owner.isDeprecated || ( owner.isRealMethod && owner.is( Synthetic ) )
909
909
910
910
/** Scan the chain of outer declaring scopes from the current context
911
911
* a deprecation warning will be skipped if one the following holds
912
912
* for a given declaring scope:
913
- * - the symbol associated with the scope is also deprecated or synthetic method.
913
+ * - the symbol associated with the scope is also deprecated or synthetic real method.
914
914
* - if and only if `sym` is an enum case, the scope is either
915
915
* a module that declares `sym`, or the companion class of the
916
916
* module that declares `sym`.
Original file line number Diff line number Diff line change 1
- @ deprecated(" no CaseClass" , " 0.1" ) case class CaseClass (rgb : Int )
1
+ @ deprecated(" no CaseClass" , " 0.1" ) case class CaseClass (rgb : Int )
You can’t perform that action at this time.
0 commit comments