FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

require a newer version of uglify that fixes a bug with regexp by bdwain · Pull Request #4902 · webpack/webpack · GitHub

require a newer version of uglify that fixes a bug with regexp - #4902

Merged
sokra merged 1 commit into
webpack:masterfrom
bdwain:master
May 20, 2017
Merged

require a newer version of uglify that fixes a bug with regexp#4902
sokra merged 1 commit into
webpack:masterfrom
bdwain:master

Conversation

bdwain commented May 19, 2017
edited
Loading

Copy link
Copy Markdown
Contributor

What kind of change does this PR introduce?
Just requiring a newer version of uglify js that includes a bugfix mishoo/UglifyJS#1964

Did you add tests for your changes?
No code changes were made.

Summary
There was a bug in earlier versions of uglify where the reduce_vars option (which is on by default) was causing some changes to the global RegExp prototype in certain scenarios (such as if babel-polyfill is included). This could break methods like string.split when using node 6 or chrome 51.

Does this PR introduce a breaking change?
No

bdwain commented May 19, 2017

Copy link
Copy Markdown
Contributor Author

cc @gaearon

bdwain commented May 19, 2017
edited
Loading

Copy link
Copy Markdown
Contributor Author

trying to get the tests passing. i can't even run the master tests locally though. i get an Error: Cannot find module 'webpack/lib/removeAndDo'

sokra commented May 19, 2017

Copy link
Copy Markdown
Member

see CONTRIBUTING.md.

yarn link
yarn link webpack

To update the test snapshots:

mocha -g "Stats"
node test/statsCases/accept-stats.js

sokra left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Update test snapshots

Copy link
Copy Markdown
Contributor

@bdwain Thanks for your update.

I labeled the Pull Request so reviewers will review it again.

@sokra Please review the new changes.

bdwain commented May 19, 2017

Copy link
Copy Markdown
Contributor Author

it's passing in travis but i still get an error locally.

  1. ConfigTestCases extract-text issue-14 should compile:
    Error: global leak detected: addresses

path = require("path");
var source = fs.readFileSync(path.join(__dirname, "ie8.js"), "utf-8");
source.should.containEql("function r(n){return function(n){try{t()}catch(t){n(t)}}}");
source.should.containEql("function r(n){return function(t){try{n()}catch(n){t(n)}}}");

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

on second thought not sure i should have switched n and t. it looks like it might change the behavior of the resulting code. but i'm not sure why the output switched either.

Copy link
Copy Markdown
Contributor

Thank you for your pull request! The most important CI builds succeeded, we’ll review the pull request soon.

sokra merged commit 6bd3a82 into webpack:master May 20, 2017

sokra commented May 20, 2017

Copy link
Copy Markdown
Member

Thanks

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL