clarified order;
authorwenzelm
Fri Sep 11 17:48:49 2015 +0200 (2015-09-11)
changeset 6115713f4056c42d7
parent 61156 931b732617a2
child 61158 ea6a4c8bc722
clarified order;
src/Pure/Tools/doc.scala
     1.1 --- a/src/Pure/Tools/doc.scala	Fri Sep 11 11:12:08 2015 +0200
     1.2 +++ b/src/Pure/Tools/doc.scala	Fri Sep 11 17:48:49 2015 +0200
     1.3 @@ -58,19 +58,24 @@
     1.4          })
     1.5  
     1.6    def contents(): List[Entry] =
     1.7 -    (for {
     1.8 -      (dir, line) <- contents_lines()
     1.9 -      entry <-
    1.10 -        line match {
    1.11 -          case Section_Entry(text) =>
    1.12 -            Library.try_unsuffix("!", text) match {
    1.13 -              case None => Some(Section(text, false))
    1.14 -              case Some(txt) => Some(Section(txt, true))
    1.15 -            }
    1.16 -          case Doc_Entry(name, title) => Some(Doc(name, title, dir + Path.basic(name)))
    1.17 -          case _ => None
    1.18 -        }
    1.19 -    } yield entry) ::: release_notes() ::: examples()
    1.20 +  {
    1.21 +    val main_contents =
    1.22 +      for {
    1.23 +        (dir, line) <- contents_lines()
    1.24 +        entry <-
    1.25 +          line match {
    1.26 +            case Section_Entry(text) =>
    1.27 +              Library.try_unsuffix("!", text) match {
    1.28 +                case None => Some(Section(text, false))
    1.29 +                case Some(txt) => Some(Section(txt, true))
    1.30 +              }
    1.31 +            case Doc_Entry(name, title) => Some(Doc(name, title, dir + Path.basic(name)))
    1.32 +            case _ => None
    1.33 +          }
    1.34 +      } yield entry
    1.35 +
    1.36 +    examples() ::: release_notes() ::: main_contents
    1.37 +  }
    1.38  
    1.39  
    1.40    /* view */
    1.41 @@ -104,4 +109,3 @@
    1.42      }
    1.43    }
    1.44  }
    1.45 -