equal
deleted
inserted
replaced
15 |
15 |
16 |
16 |
17 object Sessions |
17 object Sessions |
18 { |
18 { |
19 /* info */ |
19 /* info */ |
20 |
|
21 val ROOT = Path.explode("ROOT") |
|
22 val ROOTS = Path.explode("ROOTS") |
|
23 |
20 |
24 def is_pure(name: String): Boolean = name == "Pure" |
21 def is_pure(name: String): Boolean = name == "Pure" |
25 |
22 |
26 sealed case class Info( |
23 sealed case class Info( |
27 chapter: String, |
24 chapter: String, |
139 } |
136 } |
140 |
137 |
141 |
138 |
142 /* parser */ |
139 /* parser */ |
143 |
140 |
|
141 val ROOT = Path.explode("ROOT") |
|
142 val ROOTS = Path.explode("ROOTS") |
|
143 |
144 private val CHAPTER = "chapter" |
144 private val CHAPTER = "chapter" |
145 private val SESSION = "session" |
145 private val SESSION = "session" |
146 private val IN = "in" |
146 private val IN = "in" |
147 private val DESCRIPTION = "description" |
147 private val DESCRIPTION = "description" |
148 private val OPTIONS = "options" |
148 private val OPTIONS = "options" |
154 lazy val root_syntax = |
154 lazy val root_syntax = |
155 Outer_Syntax.init() + "(" + ")" + "+" + "," + "=" + "[" + "]" + |
155 Outer_Syntax.init() + "(" + ")" + "+" + "," + "=" + "[" + "]" + |
156 (CHAPTER, Keyword.THY_DECL) + (SESSION, Keyword.THY_DECL) + |
156 (CHAPTER, Keyword.THY_DECL) + (SESSION, Keyword.THY_DECL) + |
157 IN + DESCRIPTION + OPTIONS + GLOBAL_THEORIES + THEORIES + FILES + DOCUMENT_FILES |
157 IN + DESCRIPTION + OPTIONS + GLOBAL_THEORIES + THEORIES + FILES + DOCUMENT_FILES |
158 |
158 |
159 object Parser extends Parse.Parser |
159 private object Parser extends Parse.Parser |
160 { |
160 { |
161 private abstract class Entry |
161 private abstract class Entry |
162 private sealed case class Chapter(name: String) extends Entry |
162 private sealed case class Chapter(name: String) extends Entry |
163 private sealed case class Session_Entry( |
163 private sealed case class Session_Entry( |
164 pos: Position.T, |
164 pos: Position.T, |