A few schema documentation fixes.

Change-Id: I140e1322fc1bfb3ab8012e00d8f3006ee2e7ce95
This commit is contained in:
Wouter van Oortmerssen
2015-07-08 17:49:01 -07:00
parent d863df8683
commit d0e9bc6a75
6 changed files with 20 additions and 7 deletions

View File

@@ -2,6 +2,7 @@
schema = include*
( namespace\_decl | type\_decl | enum\_decl | root\_decl |
file_extension_decl | file_identifier_decl |
attribute\_decl | object )*
include = `include` string\_constant `;`
@@ -34,3 +35,8 @@ object = { commasep( ident `:` value ) }
value = scalar | object | string\_constant | `[` commasep( value ) `]`
commasep(x) = [ x ( `,` x )\* ]
file_extension_decl = `file_extension` string\_constant `;`
file_identifier_decl = `file_identifier` string\_constant `;`

View File

@@ -111,8 +111,11 @@ high bit yet.
### (Default) Values
Values are a sequence of digits, optionally followed by a `.` and more digits
for float constants, and optionally prefixed by a `-`. Non-scalar defaults are
currently not supported (always NULL).
for float constants, and optionally prefixed by a `-`. Floats may end with an
`e` or `E`, followed by a `+` or `-` and more digits (scientific notation).
Only scalar values can have defaults, non-scalar (string/vector/table) fields
default to NULL when not present.
You generally do not want to change default values after they're initially
defined. Fields that have the default value are not actually stored in the