1246 Commits (6bc85de25656146a3316627b3e2e1d12300d46ab)
 

Author SHA1 Message Date
Futago-za Ryuu 617b6b7425 Updated utils and tsd
- Exposed 'visitor.ASTVisitor'
- Remoed 'util.createVisitor'
- Added type 'peg.SourceLocation'
- Updated tsd for 'peg.compiler.visitor'
- Added tsd for 'peg.util.enforceFastProperties'
- Added tsd for new parser modules
6 years ago
Futago-za Ryuu 27ec5ed9b1 Ensure we are nearly always in fast mode on V8
See: https://stackoverflow.com/a/24989927/1518408
6 years ago
Futago-za Ryuu 7a19d46e8a Add the ASTVisitor class (#451)
For compatibility with pre-0.11 plugins, this class lives on the same namespace as the orignal visitor helper and also exports a static method called 'build'.
6 years ago
Futago-za Ryuu 93cc6c5b26 Parser calls AST node creator now
Before this commit, the PEG.js parser always created the AST using a plain JavaSctript object, but allthough simple and effective for the job, this method sacrificies performance slightly.

From now on the parser shall call a Node creator. This should help with performance, as well as in the future move some AST helpers into the new AST functions.
6 years ago
Futago-za Ryuu 7cdfc03e9f Added utility methods for objects
Before there used to be some internal utility methods for arrays and objects, but as the code base moved to ES5+ use  case only, these were removed in favour of native alternatives, but most of these were only beneficial for arrays.

This commit add's common utility methods for objects, and also exposes these as they can be used by plugin developer's on the PEG.js AST.
6 years ago
Futago-za Ryuu 02486cef7f ignore sh.exe stack trace file 6 years ago
Futago-za Ryuu 1b2072f239 Fix edgecase in gulpfile.js
There seem's to be an edgecase where a spawned process (in this case node.exe it self) is opened and gulp straight away thinks it closed. At first I thought it was a problem with Gulp, but after fiddleing it seem's to be a Window's problem, so I just updated the `node()` spawner to work on all platforms by using Gulp's callback to create an async task. Problem solved :)
6 years ago
Futago-za Ryuu b0056d7a9f Merge branch 'master' of github.com:pegjs/pegjs 6 years ago
Mingun 4cc9185a78 Improve error when reserved word used as label (#552)
Before this commit error looks like (for input `start = break:'a'`)

> Expected "!", "$", "&", "(", "*", "+", ".", "/", "/*", "//", ";", "?", character class, code block, comment, end of line, identifier, literal, or whitespace but ":" found.

After this error looks like

> Label can't be a reserved word "break".
6 years ago
Futago-za Ryuu 1434346332 Move require statement to the top 6 years ago
Futago-za Ryuu 93f9068c99 Updated tsd for compiler passes [ci skip] 6 years ago
Mingun fde1c480f4 Use chai-like instead of own properties matcher (#550) 6 years ago
Mingun a480c7d39c Excess points are deleted from the PR template (#551)
They already covered by `lint` and `test` checks [ci skip]
6 years ago
Mingun 534dc53ac2 Optimize redundant fail checks (#400)
eliminate unnecessary checks for the result of parse, when it can be statically determined
6 years ago
Futago-za Ryuu f5699d63fb Updated devDependencies
- Bump: eslint-config-futagozaryuu@3.8
- Bump:  run-sequence@2.2.1
6 years ago
Futago-za Ryuu cb385476c1 Updated header for generated browser files
The 'broser/*.js' files should now include the 'eslint-disable' comment directive.
6 years ago
Futago-za Ryuu 92f1798308 Moved Babel options to .babelrc 6 years ago
Futago-za Ryuu 06f1565a32 tsd: Added NotExpectation interface 6 years ago
Mingun 42ec335d13 Optimize silent fails: remove checks that always false (#399)
* Optimization: do not generate unreachable calls |peg$fail| and constants for it (local to the rule).
* Optimization: do not generate unreachable calls |peg$fail| and constants for it (non-local to rule).
6 years ago
Mingun a7a0a0d9ac Bump devDependencies (#549)
- Removed: babel-preset-es2015@6.24.1
- Added: babel-preset-env@1.6.1
- Updated: gulp-mocha@5.0.0
- Updated: nyc@11.4.1
- Updated: vinyl-buffer@1.0.1
- Updated: vinyl-source-stream@2.0.0
6 years ago
Mingun 669f782a5f Partial fix #194 - nonsenses error messages with semantic predicates (#547)
* Remove stack manipulations from FAIL opcode and rename FAIL to EXPECT
* Always save the expected values regardless of the match result of expression
* Remove unnecessary check for match result in the `named` node
* Collect and process expectations from predicates
6 years ago
Futago-za Ryuu 1b20aa5427 Ensure usage of 'lib/peg.d.ts'
This commit ensures that all modules outside 'lib' are importing 'lib/peg.js' so that VS Code automatically gets 'lib/peg.d.ts'.

An alias module for 'lib/peg.js' called 'pegjs-dev' was made for test files at 'test/node_modules/pegjs-dev.js'
6 years ago
Futago-za Ryuu 03cc2eae95 Added 'lib/peg.d.ts' for internal use 6 years ago
Futago-za Ryuu ea688abd02 Fix shadowing issue on UMD format (#499) 6 years ago
Futago-za Ryuu cd02806c94 Moved 'package.json:repository' field 6 years ago
Futago-za Ryuu 95409f0155 Moved Github related documents 6 years ago
Futago-za Ryuu 01a2be7b78 Removed 'gulp benchmark' from default tasks 6 years ago
Futago-za Ryuu d3cbbee592 Added .d.ts declaration files (#519) 6 years ago
Futago-za Ryuu a02f8091e3
Merge pull request #541 from Mingun/correct-options-in-tests
Auto-add `allowedStartRules` to test options for `changeAST` method if it not defined
6 years ago
Mingun 3e89534bb7 Auto-add `allowedStartRules` to test options for `changeAST` and `reportError` methods if it not defined 6 years ago
Futago-za Ryuu 75d655409c
Merge pull request #546 from Mingun/coverage
Add code coverage by Istanbul and coveralls.io
6 years ago
Mingun 3f8cf7cd58 Add coveralls.io support 6 years ago
Mingun f0e5eebe1a Add code coverage by Intanbul 6 years ago
Futago-za Ryuu d6142772f8 Switch dev to pegjs@dev [ci skip] 6 years ago
Futago-za Ryuu 1dd1487f9b Set version to v0.11.0-dev 6 years ago
Futago-za Ryuu db70215c4a Added 'header' option (#491) 6 years ago
Futago-za Ryuu 247a0bf707 Removed non-LTS versions of Node.js 6 years ago
Futago-za Ryuu f7dd11698a Updates devDependencies
- eslint-config-futagozaryuu
- sinon
6 years ago
Futago-za Ryuu 2a7dcdcfbe Changed 'bin/usage.txt' to 'bin/usage.js'
This change ensures the usage text always has LF line ending on Linux
6 years ago
Futago-za Ryuu 881eb67545 Removed redundant css files
The css files used in the benchmark contained 2 files for IE that contained syntax errors. These files weren't actually used by the benchmark, but were still in the repository.
6 years ago
Futago-za Ryuu a33eb0b45c Updated contribution section 6 years ago
Futago-za Ryuu 30d39f6267 Added PR Template
Based on the example at https://github.com/stevemao/github-issue-templates/tree/master/checklist2
6 years ago
Futago-za Ryuu 280466cc7b Added Issue Template
Based on the example at https://github.com/stevemao/github-issue-templates/tree/master/checklist2
6 years ago
Futago-za Ryuu 9568522d9c Move guidelines to docs folder 6 years ago
Futago-za Ryuu 123a20a83c Updated ignored and published files 6 years ago
Futago-za Ryuu 37698d8981 Updated NPM scripts & Gulp tasks
- updated names & ordering
- set "gulp clean" to also remove generated examples
- added "gulp lint" to list of default tasks
6 years ago
Futago-za Ryuu b4e5b97a2e Disabled eslint rule 'prefer-spread' 7 years ago
Futago-za Ryuu 5f0001c3e5 Fix compatibility for older bins 7 years ago
Futago-za Ryuu e6d018a88d Update code format and style
This is related to my last commit. I've updated all the JavaScript files to satisfy 'eslint-config-futagozaryuu', my eslint configuration.

I'm sure I've probally missed something, but I've run all NPM scripts and Gulp tasks, fixed any bugs that cropped up, and updated some stuff (mainly related to generated messages), so as far as I can, tell this conversion is over (I know I've probally jixed it just by saying this ;P).
7 years ago
Futago-za Ryuu 3c6523ff83 Switched eslint configuration
Was using 'eslint-config-dmajda' by @dmajda, but since it's diffucult for me to use multiple styles across multiple projects, I'm switching to my own 'eslint-config-futagozaryuu'.
7 years ago