summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKota Mizushima <mizukota@gmail.com>2016-03-17 20:17:43 +0900
committerKota Mizushima <mizukota@gmail.com>2016-03-17 20:17:43 +0900
commitca741091c898e17d082c496443b6b258ef4020e8 (patch)
tree102e87c5173aeef42b0f0f46a448774f335f333d /src
parentb5bac6e5935ba25721d10fc0d9cd154ce536c3db (diff)
downloadscala-ca741091c898e17d082c496443b6b258ef4020e8.tar.gz
scala-ca741091c898e17d082c496443b6b258ef4020e8.tar.bz2
scala-ca741091c898e17d082c496443b6b258ef4020e8.zip
* Replace isPackage with hasPackageFlag
Diffstat (limited to 'src')
-rw-r--r--src/compiler/scala/tools/nsc/typechecker/Contexts.scala2
-rw-r--r--src/reflect/scala/reflect/internal/Symbols.scala2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/typechecker/Contexts.scala b/src/compiler/scala/tools/nsc/typechecker/Contexts.scala
index cb4eab335b..bb7dc3746b 100644
--- a/src/compiler/scala/tools/nsc/typechecker/Contexts.scala
+++ b/src/compiler/scala/tools/nsc/typechecker/Contexts.scala
@@ -978,7 +978,7 @@ trait Contexts { self: Analyzer =>
*/
def isInPackageObject(sym: Symbol, pkg: Symbol): Boolean = {
if (sym.isOverloaded) sym.alternatives.exists(alt => isInPackageObject(alt, pkg))
- else pkg.isPackage && sym.owner != pkg && requiresQualifier(sym)
+ else pkg.hasPackageFlag && sym.owner != pkg && requiresQualifier(sym)
}
def isNameInScope(name: Name) = lookupSymbol(name, _ => true).isSuccess
diff --git a/src/reflect/scala/reflect/internal/Symbols.scala b/src/reflect/scala/reflect/internal/Symbols.scala
index 9a3f6a6f3f..0a044b23d9 100644
--- a/src/reflect/scala/reflect/internal/Symbols.scala
+++ b/src/reflect/scala/reflect/internal/Symbols.scala
@@ -838,7 +838,7 @@ trait Symbols extends api.Symbols { self: SymbolTable =>
/** The package object symbol corresponding to this package or package class symbol, or NoSymbol otherwise */
def packageObject: Symbol =
if (isPackageClass) tpe.packageObject
- else if (isPackage) moduleClass.packageObject
+ else if (hasPackageFlag) moduleClass.packageObject
else NoSymbol
/** If this is a constructor, its owner: otherwise this.