User Tools

Site Tools


documentation:tiny2

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
documentation:tiny2 [2023/09/16 14:07] – Move comments before other subsections nebelnidasdocumentation:tiny2 [2023/09/16 21:23] (current) – Add missing inline code markers nebelnidas
Line 26: Line 26:
 ===== Grammar ===== ===== Grammar =====
 <code> <code>
-<file>                          ::= <header> | <header> <sections>+<file>                          ::= <header> | <header> <content>
  
 <header>                        ::= 'tiny' <tab> <major-version> <tab> <minor-version> <tab> <namespace-a> <tab> <namespace-b> <extra-namespaces> <eol> <properties> <header>                        ::= 'tiny' <tab> <major-version> <tab> <minor-version> <tab> <namespace-a> <tab> <namespace-b> <extra-namespaces> <eol> <properties>
Line 41: Line 41:
 <property-value>                ::= <escaped-string> <property-value>                ::= <escaped-string>
  
-<sections                     ::= '' | <class-section> <sections>+<content                      ::= '' | <class-section> <content>
  
 <class-section>                 ::= 'c' <tab> <class-name-a> <tab> <class-name-b> <extra-ns-class-names> <eol> <class-sub-sections> <class-section>                 ::= 'c' <tab> <class-name-a> <tab> <class-name-b> <extra-ns-class-names> <eol> <class-sub-sections>
Line 98: Line 98:
   * ''%%<safe-string>%%'' is a non-empty string that must not contain:   * ''%%<safe-string>%%'' is a non-empty string that must not contain:
     * ''\'',     * ''\'',
-    * ''"\n"'', +    * ''\n'', 
-    * ''"\r"'', +    * ''\r'', 
-    * ''"\t"'' or +    * ''\t'' or 
-    * ''"\0"''.+    * ''\0''.
   * ''%%<conf-safe-string>%%'' is the same as ''%%<safe-string>%%'' if ''%%<properties>%%'' doesn't contain a ''%%<property>%%'' ''escaped-names'', otherwise it's a non-empty string further described by ''%%<escaped-string>%%''.   * ''%%<conf-safe-string>%%'' is the same as ''%%<safe-string>%%'' if ''%%<properties>%%'' doesn't contain a ''%%<property>%%'' ''escaped-names'', otherwise it's a non-empty string further described by ''%%<escaped-string>%%''.
-  * ''%%<escaped-string>%%'' is a string that must not contain ''%%<eol>%%'' and escapes+  * ''%%<escaped-string>%%'' is a string that must not contain an ''%%<eol>%%''escapes ''\'' to ''\\'' and the other forbidden values to their string literal equivalentsas seen in the list above.
-    *  ''\'' to ''\\''+
-    * ''"\n"'' to ''\n'', +
-    * ''"\r"'' to ''\r'', +
-    * ''"\t"'' to ''\t'' and +
-    * ''"\0"'' to ''\0''.+
   * ''%%<non-negative-int>%%'' is any integer from 0 to 2147483647 (2^31-1) inclusive, represented as per ''java.lang.Integer.toString()''.   * ''%%<non-negative-int>%%'' is any integer from 0 to 2147483647 (2^31-1) inclusive, represented as per ''java.lang.Integer.toString()''.
   * ''%%<class-name>%%'', once optionally unescaped, is the binary name of a class as specified in JVMS SE 8 §4.2.1. Nested class identifiers are typically separated with ''$'' (e.g. ''some/package/class$nested$subnested''). Outer names must not be omitted for any namespace.   * ''%%<class-name>%%'', once optionally unescaped, is the binary name of a class as specified in JVMS SE 8 §4.2.1. Nested class identifiers are typically separated with ''$'' (e.g. ''some/package/class$nested$subnested''). Outer names must not be omitted for any namespace.
Line 123: Line 118:
   * Indenting uses tab characters exclusively, one tab character equals one level. The amount of leading tab characters is at most 1 more than in the preceding line.   * Indenting uses tab characters exclusively, one tab character equals one level. The amount of leading tab characters is at most 1 more than in the preceding line.
   * Sections or properties with unknown types/keys should be skipped without generating an error.   * Sections or properties with unknown types/keys should be skipped without generating an error.
-  * The amount of extra namespaces defined in the header and the amount of names in every ''%%extra-ns-*-names%%'' definition have to match. They are associated by their relative position, like the mandatory name spaces a and b that are associated by the suffix, e.g. ''%%namespace-a%%'' covers ''%%class-name-a%%'', ''%%field-name-a%%'', ''%%field-desc-a%%'', ''%%method-name-a%%'', ''%%method-desc-a%%'' and ''%%var-desc-a%%'',.+  * The amount of extra namespaces defined in the header and the amount of names in every ''%%extra-ns-*-names%%'' definition have to match. They are associated by their relative position, like the mandatory name spaces ''a'' and ''b'' that are associated by the suffix, e.g. ''%%namespace-a%%'' covers ''%%class-name-a%%'', ''%%field-name-a%%'', ''%%field-desc-a%%'', ''%%method-name-a%%'', ''%%method-desc-a%%'' and ''%%var-desc-a%%'',.
   * Sections representing the same element must not be repeated, e.g. there can be only one top-level section for a specific class or one class-level section for a specific member.   * Sections representing the same element must not be repeated, e.g. there can be only one top-level section for a specific class or one class-level section for a specific member.
   * If any variable mapping doesn't specify a LVT index, e.g. due to a missing ''LocalVariableTable'' attribute in one of the methods, the property ''missing-lvt-indices'' has to be added to.   * If any variable mapping doesn't specify a LVT index, e.g. due to a missing ''LocalVariableTable'' attribute in one of the methods, the property ''missing-lvt-indices'' has to be added to.
documentation/tiny2.1694873277.txt.gz · Last modified: 2023/09/16 14:07 by nebelnidas