diff options
author | Jason Zaugg <jzaugg@gmail.com> | 2013-02-24 23:31:52 +0100 |
---|---|---|
committer | Jason Zaugg <jzaugg@gmail.com> | 2013-02-24 23:31:52 +0100 |
commit | 6e450ed030aa7a5af53475f1613257a8e12322bc (patch) | |
tree | 235cb04360899d5261210e20614f9b2497083cf8 | |
parent | 8cdf3b3f51adff8dbeff5217505f74cfbedb55cd (diff) | |
download | scala-6e450ed030aa7a5af53475f1613257a8e12322bc.tar.gz scala-6e450ed030aa7a5af53475f1613257a8e12322bc.tar.bz2 scala-6e450ed030aa7a5af53475f1613257a8e12322bc.zip |
Reorder to avoid code appearing like a forward reference.
It isn't, because LOOP_HEADER and friends are compile time
constants. But I'd argue that its clearer not to rely on that here.
-rw-r--r-- | src/compiler/scala/tools/nsc/backend/icode/BasicBlocks.scala | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/compiler/scala/tools/nsc/backend/icode/BasicBlocks.scala b/src/compiler/scala/tools/nsc/backend/icode/BasicBlocks.scala index 24c18e6530..cc10479ca1 100644 --- a/src/compiler/scala/tools/nsc/backend/icode/BasicBlocks.scala +++ b/src/compiler/scala/tools/nsc/backend/icode/BasicBlocks.scala @@ -500,18 +500,6 @@ trait BasicBlocks { } object BBFlags { - val flagMap = Map[Int, String]( - LOOP_HEADER -> "loopheader", - IGNORING -> "ignore", - EX_HEADER -> "exheader", - CLOSED -> "closed", - DIRTYSUCCS -> "dirtysuccs", - DIRTYPREDS -> "dirtypreds" - ) - def flagsToString(flags: Int) = { - flagMap collect { case (bit, name) if (bit & flags) != 0 => "<" + name + ">" } mkString " " - } - /** This block is a loop header (was translated from a while). */ final val LOOP_HEADER = (1 << 0) @@ -529,4 +517,16 @@ object BBFlags { /** Code has been changed, recompute predecessors. */ final val DIRTYPREDS = (1 << 5) + + val flagMap = Map[Int, String]( + LOOP_HEADER -> "loopheader", + IGNORING -> "ignore", + EX_HEADER -> "exheader", + CLOSED -> "closed", + DIRTYSUCCS -> "dirtysuccs", + DIRTYPREDS -> "dirtypreds" + ) + def flagsToString(flags: Int) = { + flagMap collect { case (bit, name) if (bit & flags) != 0 => "<" + name + ">" } mkString " " + } } |