Comparing version 0.0.5 to 0.0.6
@@ -8,3 +8,3 @@ // **N3Lexer** tokenizes N3 documents. | ||
_tripleQuotedString: /^""("[^"\\]*(?:(?:\\.|"(?!""))[^"\\]*)*")""/, | ||
_langcode: /^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9\-])/, | ||
_langcode: /^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9\-])/i, | ||
_prefix: /^([A-Z_a-z\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c-\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd][\-0-9A-Z_a-z\u00b7\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u037d\u037f-\u1fff\u200c-\u200d\u203f-\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]*)?:(?=\s)/, | ||
@@ -11,0 +11,0 @@ _qname: /^([A-Z_a-z\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c-\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd][\-0-9A-Z_a-z\u00b7\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u037d\u037f-\u1fff\u200c-\u200d\u203f-\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]*)?:((?:[A-Z_a-z\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c-\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd][\-0-9A-Z_a-z\u00b7\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u037d\u037f-\u1fff\u200c-\u200d\u203f-\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]*)?)(?=[\s\.;,])/, |
@@ -228,3 +228,3 @@ // **N3Parser** parses N3 documents. | ||
case 'langcode': | ||
this._object += '@' + token.value; | ||
this._object += '@' + token.value.toLowerCase(); | ||
return this._getNextReader(); | ||
@@ -231,0 +231,0 @@ default: |
{ | ||
"name": "n3", | ||
"version": "0.0.5", | ||
"version": "0.0.6", | ||
"description": "Notation3 (N3) and RDF library.", | ||
"author": "Ruben Verborgh <ruben.verborgh@gmail.com>", | ||
"keywords": ["n3", "notation3", "rdf"], | ||
"keywords": ["n3", "notation3", "turtle", "rdf"], | ||
"main": "./n3.js", | ||
@@ -8,0 +8,0 @@ "engines": { |
@@ -93,3 +93,3 @@ var N3Lexer = require('../lib/n3lexer.js'); | ||
'should tokenize a quoted string literal with language code': | ||
shouldTokenize('"string"@en "string"@nl-be ', | ||
shouldTokenize('"string"@en "string"@nl-be "string"@EN ', | ||
{ type: 'literal', value: '"string"', line: 1 }, | ||
@@ -99,2 +99,4 @@ { type: 'langcode', value: 'en', line: 1 }, | ||
{ type: 'langcode', value: 'nl-be', line: 1 }, | ||
{ type: 'literal', value: '"string"', line: 1 }, | ||
{ type: 'langcode', value: 'EN', line: 1 }, | ||
{ type: 'eof', line: 1 }), | ||
@@ -101,0 +103,0 @@ |
@@ -61,2 +61,6 @@ var N3Parser = require('../lib/n3parser.js'); | ||
'should normalize language codes to lowercase': | ||
shouldParse('<a> <b> "string"@EN.', | ||
['a', 'b', '"string"@en']), | ||
'should parse a triple with a literal and a URI type': | ||
@@ -63,0 +67,0 @@ shouldParse('<a> <b> "string"^^<type>.', |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
87529
1885