Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make information block optional in syntax, but point out it will be needed #24

Merged
merged 3 commits into from Mar 11, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion sdf-feature.cddl
@@ -1,7 +1,7 @@
start = sdf-syntax

sdf-syntax = {
info: sdfinfo ; don't *require* this in flexible syntax, though
? info: sdfinfo ; This will be required in most process policies, but not a syntax error
? namespace: named<text>
? defaultNamespace: text
? sdfThing: named<thingqualities> ; Thing is a composition of objects that work together in some way
Expand Down
2 changes: 1 addition & 1 deletion sdf-framework.cddl
@@ -1,7 +1,7 @@
start = sdf-syntax

sdf-syntax = {
info: sdfinfo ; don't *require* this in flexible syntax, though
? info: sdfinfo ; This will be required in most process policies, but not a syntax error
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

although not a syntax error, a warning should be given that this block is missing

? namespace: named<text>
? defaultNamespace: text
? sdfThing: named<thingqualities> ; Thing is a composition of objects that work together in some way
Expand Down
3 changes: 0 additions & 3 deletions sdf-framework.jso.json
Expand Up @@ -5,9 +5,6 @@
"definitions": {
"sdf-syntax": {
"type": "object",
"required": [
"info"
],
"properties": {
"info": {
"$ref": "#/definitions/sdfinfo"
Expand Down
2 changes: 1 addition & 1 deletion sdf-validation.cddl
@@ -1,7 +1,7 @@
start = sdf-syntax

sdf-syntax = {
info: sdfinfo ; don't *require* this in flexible syntax, though
? info: sdfinfo ; This will be required in most process policies, but not a syntax error
? namespace: named<text>
? defaultNamespace: text
? sdfThing: named<thingqualities> ; Thing is a composition of objects that work together in some way
Expand Down
3 changes: 0 additions & 3 deletions sdf-validation.jso.json
Expand Up @@ -5,9 +5,6 @@
"definitions": {
"sdf-syntax": {
"type": "object",
"required": [
"info"
],
"properties": {
"info": {
"$ref": "#/definitions/sdfinfo"
Expand Down
138 changes: 69 additions & 69 deletions sdf.html

Large diffs are not rendered by default.

3 changes: 0 additions & 3 deletions sdf.jso.json-unidiff
Expand Up @@ -6,9 +6,6 @@
"definitions": {
"sdf-syntax": {
"type": "object",
"required": [
"info"
],
"properties": {
"info": {
"$ref": "#/definitions/sdfinfo"
Expand Down
3 changes: 3 additions & 0 deletions sdf.md
Expand Up @@ -496,6 +496,9 @@ This object has three sections: the information block, the namespaces section, a
## Information block

The information block contains generic meta data for the file itself and all included definitions.
To enable tool integration, the information block is optional in the grammar
of SDF; most processes for working with SDF files will have policies
that only SDF models with an info block can be processed.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Syntax verification tooling should give a warning (but not fail) when this block is missing.


The keyword (map key) that defines an information block is "info". Its
value is a JSON map in turn, with a set of entries that represent qualities that apply to the included definition.
Expand Down