Reduce createIterator.

Former-commit-id: 8c27ca8e4d1f71b2727dd988bc62194510a850dc
This commit is contained in:
John-David Dalton
2012-10-03 23:48:19 -07:00
parent 25ba18e570
commit 21217dfda3
4 changed files with 27 additions and 37 deletions

View File

@@ -684,7 +684,7 @@
// remove `isKeysFast` from `inLoop.object` of `mapIteratorOptions`, `invoke`, `pairs`, `pluck`, and `sortBy`
.replace(/'\s*\+\s*\(isKeysFast[^)]+?\)\s*\+\s*'/g, '.push')
// remove data object property assignment in `createIterator`
.replace(/\s*.+?\.isKeysFast *=.+/, '');
.replace(/ *'isKeysFast':.+\n/, '');
}
/**
@@ -795,10 +795,8 @@
.replace(/(?: *\/\/.*\n)*(\s*)' *<% *if *\(useStrict\).+/, value ? "$1'\\'use strict\\';\\n' +" : '')
// remove `useStrict` from iterator options
.replace(/ *'useStrict': *false,\n/g, '')
// remove `useStrict` variable assignment in `createIterator`
.replace(/,\s*useStrict *=[^;]+/, '')
// remove `useStrict` data object property assignment in `createIterator`
.replace(/\s*.+?\.useStrict *=.+/, '');
.replace(/ *'useStrict':.+\n/, '');
}
/*--------------------------------------------------------------------------*/