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

All Elements: Properties with no value in NCL #6

Open
ghost opened this issue Nov 1, 2017 · 1 comment
Open

All Elements: Properties with no value in NCL #6

ghost opened this issue Nov 1, 2017 · 1 comment

Comments

@ghost
Copy link

ghost commented Nov 1, 2017

  • When the value is "default" in sNCL, the propertie is written is NCL with no value (I prefer this one)
media media1
   left: "default"
end
  • Parse properties with no value in sNCL
media media1
   left
end
@robertogerson
Copy link
Collaborator

robertogerson commented Nov 6, 2017

Wouldn't an empty string be enough for what you want to do?

For consistency and to avoid unnecessary complications in the parser my suggestion is to keep the "propname: value" syntax even for properties with no values. Thus, if we really need a string with no value, we will probably need a keyword for it (such as novalue, nil or empty). Just some experiments:

media media1
   left: ""
  # or
  left: nil
  # or
  left: empty
  #
  left: novalue
end

But, do we really need it? Is there an interesting use case for adding such a support?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant