yaml-ast-parser
Advanced tools
Comparing version 0.0.41 to 0.0.42
{ | ||
"name": "yaml-ast-parser", | ||
"version": "0.0.41", | ||
"version": "0.0.42", | ||
"main": "dist/src/index.js", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -28,3 +28,3 @@ import ast=require("./yamlAST") | ||
var PATTERN_NON_PRINTABLE = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uD800-\uDFFF\uFFFE\uFFFF]/; | ||
var PATTERN_NON_PRINTABLE = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/; | ||
var PATTERN_NON_ASCII_LINE_BREAKS = /[\x85\u2028\u2029]/; | ||
@@ -351,3 +351,6 @@ var PATTERN_FLOW_INDICATORS = /[,\[\]\{\}]/; | ||
} | ||
} else if (PATTERN_NON_PRINTABLE.test(_result)) { | ||
throwError(state, 'the stream contains non-printable characters'); | ||
} | ||
scalar.value+=_result; | ||
@@ -1746,4 +1749,4 @@ scalar.endPosition=end; | ||
let inputLength = input.length; | ||
if (inputLength !== 0) { | ||
let inputLength = input.length; | ||
if (inputLength !== 0) { | ||
@@ -1764,6 +1767,2 @@ // Add tailing `\n` if not exists | ||
if (PATTERN_NON_PRINTABLE.test(state.input)) { | ||
throwError(state, 'the stream contains non-printable characters'); | ||
} | ||
// Use 0 as string terminator. That significantly simplifies bounds check. | ||
@@ -1770,0 +1769,0 @@ state.input += '\0'; |
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
410387
155
8023