src/Pure/Isar/token.scala
changeset 58753 960bf499ca5d
parent 58751 6de7dbaf3c44
child 58861 5ff61774df11
equal deleted inserted replaced
58752:2077bc9558cf 58753:960bf499ca5d
   190     source.startsWith(Symbol.open_decoded))
   190     source.startsWith(Symbol.open_decoded))
   191 
   191 
   192   def is_begin: Boolean = is_keyword && source == "begin"
   192   def is_begin: Boolean = is_keyword && source == "begin"
   193   def is_end: Boolean = is_command && source == "end"
   193   def is_end: Boolean = is_command && source == "end"
   194 
   194 
       
   195   def is_begin_block: Boolean = is_command && source == "{"
       
   196   def is_end_block: Boolean = is_command && source == "}"
       
   197 
   195   def content: String =
   198   def content: String =
   196     if (kind == Token.Kind.STRING) Scan.Parsers.quoted_content("\"", source)
   199     if (kind == Token.Kind.STRING) Scan.Parsers.quoted_content("\"", source)
   197     else if (kind == Token.Kind.ALT_STRING) Scan.Parsers.quoted_content("`", source)
   200     else if (kind == Token.Kind.ALT_STRING) Scan.Parsers.quoted_content("`", source)
   198     else if (kind == Token.Kind.VERBATIM) Scan.Parsers.verbatim_content(source)
   201     else if (kind == Token.Kind.VERBATIM) Scan.Parsers.verbatim_content(source)
   199     else if (kind == Token.Kind.CARTOUCHE) Scan.Parsers.cartouche_content(source)
   202     else if (kind == Token.Kind.CARTOUCHE) Scan.Parsers.cartouche_content(source)