aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/core/Flags.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2013-07-19 16:11:10 +0200
committerMartin Odersky <odersky@gmail.com>2013-07-19 17:02:03 +0200
commitea640a32264cb78efbf267d5c2be89e3e99dcccf (patch)
treee4c3103d9d08580d9ef478763fb52c80548feef8 /src/dotty/tools/dotc/core/Flags.scala
parent17ef71dc2b11c5d1a82307f79d50c7ed0f77fd81 (diff)
downloaddotty-ea640a32264cb78efbf267d5c2be89e3e99dcccf.tar.gz
dotty-ea640a32264cb78efbf267d5c2be89e3e99dcccf.tar.bz2
dotty-ea640a32264cb78efbf267d5c2be89e3e99dcccf.zip
Additions needed to support implicits.
Still to do: - properly account for bounded wildcard types - set up scheme for nested diagnostics buffers.
Diffstat (limited to 'src/dotty/tools/dotc/core/Flags.scala')
-rw-r--r--src/dotty/tools/dotc/core/Flags.scala19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/dotty/tools/dotc/core/Flags.scala b/src/dotty/tools/dotc/core/Flags.scala
index 82fd86c05..045a511de 100644
--- a/src/dotty/tools/dotc/core/Flags.scala
+++ b/src/dotty/tools/dotc/core/Flags.scala
@@ -203,18 +203,14 @@ object Flags {
final val TypeParam = Param.toTypeFlags
/** Labeled with `implicit` modifier (implicit value) */
- final val Implicit = termFlag(9, "implicit")
-
- /** A trait */
- final val Trait = typeFlag(9, "<trait>")
+ final val ImplicitCommon = commonFlag(9, "implicit")
+ final val Implicit = ImplicitCommon.toTermFlags
/** Labeled with `lazy` (a lazy val). */
final val Lazy = termFlag(10, "lazy")
- /** A trait that has only abstract methods as members
- * (and therefore can be represented by a Java interface
- */
- final val Interface = typeFlag(10, "interface")
+ /** A trait */
+ final val Trait = typeFlag(10, "<trait>")
/** A value or variable accessor (getter or setter) */
final val Accessor = termFlag(11, "<accessor>")
@@ -273,6 +269,11 @@ object Flags {
/** Method is a label. */
final val Label = termFlag(22, "<label>")
+ /** A trait that has only abstract methods as members
+ * (and therefore can be represented by a Java interface
+ */
+ final val Interface = typeFlag(22, "interface")
+
/** Labeled with `abstract` modifier (an abstract class)
* Note: You should never see Abstract on any symbol except a class.
* Note: the flag counts as common, because it can be combined with OVERRIDE in a term.
@@ -380,7 +381,7 @@ object Flags {
final val FromStartFlags =
AccessFlags | Module | Package | Deferred | Param | Scala2ExistentialCommon | Touched |
Static | CovariantCommon | ContravariantCommon | ExpandedName | AccessorOrSealed | Frozen |
- Erroneous
+ Erroneous | ImplicitCommon
assert(FromStartFlags.isTermFlags && FromStartFlags.isTypeFlags)
// TODO: Should check that FromStartFlags do not change in completion