AlaSQL / alasql-sqllogictest

sqllogictest for AlaSQL
MIT License
1 stars 1 forks source link

[Snyk] Upgrade pegjs from 0.9.0 to 0.10.0 #7

Closed snyk-bot closed 4 years ago

snyk-bot commented 4 years ago

Snyk has created this PR to upgrade pegjs from 0.9.0 to 0.10.0.

:information_source: Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.


Release notes
Package name: pegjs
  • 0.10.0 - 2016-08-19

    Major Changes

    • Parsers can be generated in multiple module formats. The available
      formats are: CommonJS (the default), AMD, UMD, globals, and bare (not
      available from the command-line).

      The format can be specified using the format option of the peg.generate
      function or the --format option on the command-line.

      It is also possible to specify parser dependencies using the dependencies
      option of the peg.generate function or the --dependency/-d option on
      the command-line. This is mainly useful for the UMD format, where the
      dependencies are translated into both AMD dependencies and CommonJS
      require calls.

    • Browser version of PEG.js is now in the UMD format. This means it will try
      to detect AMD or Node.js/CommonJS module loader and define itself as a
      module. If no loader is found, it will export itself using a global
      variable.

    • API polishing. The peg.buildParser function was renamed to
      peg.generate. The global variable the browser version of PEG.js is
      available in when no loader is detected was renamed from PEG to peg.

    • CLI improvements. There is new --output/-o command-line option which
      allows to specify the output file. The old way of specifying the output file
      using a second argument was removed. To make room for the new -o option
      the old one (a shortcut for --optimize) was renamed to -O. All these
      changes make PEG.js conform to traditional compiler command-line interface.

      It is now also possible to use - as a file name on the command-line (with
      the usual meaning of standard input/output).

    • Improved error messages. Both messages produced by PEG.js and generated
      parsers were improved.

    • Duplicate rule definitions are reported as errors.

    • Duplicate labels are reported as errors.

    Minor Changes

    • Exposed the AST node visitor builder as peg.compiler.visitor. This is
      useful mainly for plugins which manipulate the AST.
    • Exposed the function which builds messages of exceptions produced by
      generated parsers as SyntaxError.buildMessage. This is useful mainly for
      customizing these error messages.
    • The error and expected functions now accept an optional location
      parameter. This allows to customize the location in which the resulting
      syntax error is reported.
    • Refactored expectations reported in the expected property of exceptions
      produced by generated parsers. They are no longer de-duplicated and sorted,
      their format changed to be more machine-readable, and they no longer contain
      human-readable descriptions.
    • The found property of exceptions produced by the error function is now
      set to null.
    • Removed access to the parser object in parser code via the parser
      variable.
    • Made handling of optional parameters consistent with ES 2015. Specifically,
      passing undefined as a parameter value is now equivalent to not passing
      the parameter at all.
    • Renamed several compiler passes.
    • Generated parsers no longer consider \r, \u2028, and \u2029 as
      newlines (only \n and \r\n).
    • Simplified the arithmetics example grammar.
    • Switched from first/rest to head/tail in PEG.js grammar and example
      grammars.
    • Started using ESLint instead of JSHint and fixed various problems it found.
    • Added contribution
      guidelines
      .
    • Removed support for io.js.

    Bug Fixes

    • Fixed bin/pegjs so that invoking it with one non-option argument which is
      an extension-less file doesn’t cause that file to be overwritten.
    • Fixed label scoping so that labels in expressions like (a:"a") or (a:"a" b:"b" c:"c") aren’t visible from the outside.
    • Fixed escaping of generated JavaScript strings & regexps to also escape DEL
      (U+007F).
    • Fixed the JSON example grammar to correctly handle characters with code
      points above U+10FF in strings.
    • Fixed multiple compatibility issues of tools/impact on OS X.
    • Fixed slow deduplication of expectation descriptions.

    Complete set of changes

  • 0.9.0 - 2015-08-30

    Major Changes

    • Tracing support. Parsers can be compiled with support for tracing their
      progress, which can help debugging complex grammars. This feature is
      experimental and is expected to evolve over time as experience is gained.
      More details
    • Infinite loop detection. Grammar constructs that could cause infinite
      loops in generated parsers are detected during compilation and cause errors.
    • Improved location information API. The line, column, and offset
      functions available in parser code were replaced by a single location
      function which returns an object describing the current location. Similarly,
      the line, column, and offset properties of exceptions were replaced by
      a single location property. The location is no longer a single point but a
      character range, which is meaningful mainly in actions where the range
      covers action’s expression.
      More details
    • Improved error reporting. All exceptions thrown when generating a parser
      have associated location information. And all exceptions thrown by generated
      parser and PEG.js itself have a stack trace (the stack property) in
      environments that support Error.captureStackTrace.
    • Strict mode code. All PEG.js and generated parser code is written using
      JavaScript strict mode.

    Minor Changes

    • Labels behave like block-scoped variables. This means parser code can see
      labels defined outside expressions containing code.
    • Empty sequences are no longer allowed.
    • Label names can’t be JavaScript reserved words.
    • Rule and label names can contain Unicode characters like in JavaScript.
    • Rules have to be separated either by ; or a newline (until now, any
      whitespace was enough).
    • The PEG.js grammar and all the example grammars were completely rewritten.
      This rewrite included a number of cleanups, formatting changes, naming
      changes, and bug fixes.
    • The parser object can now be accessed as parser in parser code.
    • Location information computation is faster.
    • Added support for Node.js >= 0.10.x, io.js, and Edge. Removed support for
      Node.js < 0.10.x.

    Bug Fixes

    • Fixed left recursion detector which missed many cases.
    • Fixed escaping of U+0100—U+107F and U+1000—U+107F in generated code and
      error messages.
    • Renamed parse and SyntaxError to peg$parse and peg$SyntaxError to
      mark them as internal identifiers.

    Complete set of changes

from pegjs GitHub release notes
Commit messages
Package name: pegjs
  • 671166b Update version to 0.10.0
  • 86c040e Update CHANGELOG.md
  • 8003eda Rename the "node" module format to "commonjs"
  • 8962dcf Rename the "global" module format to "globals"
  • 0478f8a package.json: Sort files alphabetically
  • b77d33c generate-js.js: Quote the "class" key in DESCRIBE_EXPECTATION_FNS
  • 2a8544d README.md: Remove io.js from the list of compatible environments
  • 5c0f0ad Downgrade eslint to 2.13.1
  • f092714 Use jQuery.scrollTo 2.1.2
  • 0753d8d Use jQuery 1.12.4
  • 9446e07 Use uglify-js 2.7.0
  • a8d01e1 Use eslint 3.2.0
  • e6c3e71 Use browserify 13.1.0
  • 2647f57 generated-parser-behavior.spec.js: Test also with options.trace === true
  • bf9d956 Tighten "try ... catch" clauses in spec helpers
  • 67d85f2 Align names of compiler passes that detect infinite loops
  • 9717dc3 Talk about "undefined rules" instead of "missing rules" internally
  • e9cb236 Split peg$buildException into two separate functions
  • e03d924 Set the "found" property of syntax errors produced by "error" to null
  • 6ca546a Regenerate lib/parser.js
  • 75cd17e bin/pegjs: Implement the --format option
  • d83e4d5 bin/pegjs: Generate parsers in "node" format
  • db9920e peg.generate: Implement { format: "global" }
  • 61c11ee peg.generate: Implement { format: "amd" }
Compare

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs.

For more information:

🧐 View latest project report

🛠 Adjust upgrade PR settings

🔕 Ignore this dependency or unsubscribe from future upgrade PRs