Skip to content

Commit

Permalink
Tignten up direction part of LANGDIR terminal.
Browse files Browse the repository at this point in the history
  • Loading branch information
gkellogg committed Jul 15, 2023
1 parent 31a02d8 commit 0dd3ed0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion etc/n-triples.ebnf
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ quotedTriple ::= '<<' subject predicate object '>>'

IRIREF ::= '<' ([^#x00-#x20<>"{}|^`\] | UCHAR)* '>'
BLANK_NODE_LABEL ::= '_:' ( PN_CHARS_U | [0-9] ) ((PN_CHARS|'.')* PN_CHARS)?
LANGDIR ::= "@" [a-zA-Z]+ ( "-" [a-zA-Z0-9]+ )* ('--' ('ltr'|'rtl'))?`
LANGDIR ::= "@" [a-zA-Z]+ ( "-" [a-zA-Z0-9]+ )* ('--' [a-zA-Z]+)?`
STRING_LITERAL_QUOTE ::= '"' ( [^#x22#x5C#xA#xD] | ECHAR | UCHAR )* '"'
UCHAR ::= ( "\u" HEX HEX HEX HEX )
| ( "\U" HEX HEX HEX HEX HEX HEX HEX HEX )
Expand Down
2 changes: 1 addition & 1 deletion lib/rdf/ntriples/reader.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ class Reader < RDF::Reader

IRIREF = /<((?:#{IRI_RANGE}|#{UCHAR})*)>/.freeze
BLANK_NODE_LABEL = /_:((?:[0-9]|#{PN_CHARS_U})(?:(?:#{PN_CHARS}|\.)*#{PN_CHARS})?)/.freeze
LANGDIR = /@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*(?:--[a-zA-Z0-9]+)?)/.freeze
LANGDIR = /@([a-zA-Z]+(?:-[a-zA-Z0-9]+)*(?:--[a-zA-Z]+)?)/.freeze
STRING_LITERAL_QUOTE = /"((?:[^\"\\\n\r]|#{ECHAR}|#{UCHAR})*)"/.freeze

ST_START = /^<</.freeze
Expand Down

0 comments on commit 0dd3ed0

Please sign in to comment.