shexSpec / shex

ShEx language issues, including new features for e.g. ShEx2.1
24 stars 8 forks source link

Token for "any language-tagged string" #78

Closed ericprud closed 6 years ago

ericprud commented 6 years ago

This text was moved to a response to #74.

I had an action item to draft a proposal for an intuitive token for "any language-tagged string". I ended up using @~ instead of @* (see shex.js example). This worked in shex.js with fewer than 10 changed lines.

<#LangString> rdf:langString

<#LangStem> [@en~]

<#Empty> [@~]

<#EmptyExclEN> [@~ - @en] # rejects "ab"@en

<#EmptyExclFR> [@~ - @fr]

# <#EmptyExclEmpty> [@~ - @~] <-- not valid in grammar

# <#DotExclEmpty> [. - @~] <-- not valid in grammar