Ignore:
Timestamp:
Dec 6, 2007, 12:24:52 PM (18 years ago)
Author:
Darin Adler
Message:

JavaScriptCore:

Reviewed by Eric Seidel.

Test: fast/js/regexp-oveflow.html

  • pcre/pcre_compile.cpp: (calculateCompiledPatternLengthAndFlags): In the case where a single character character class is optimized to not use a character class at all, the preflight code was not setting the lastitemlength variable.

LayoutTests:

Reviewed by Eric Seidel.

  • fast/js/regexp-overflow-expected.txt: Updated.
  • fast/js/resources/regexp-overflow.js: Added test.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/fast/js/resources/regexp-overflow.js

    r28395 r28491  
    1515shouldBe('/(x){0,2}/.exec("").toString()', '","');
    1616
     17shouldBe('/[\u00A1]{4,6}/.exec("\u00A1\u00A1\u00A1\u00A1").toString()', '"\u00A1\u00A1\u00A1\u00A1"');
     18shouldBe('/[\u00A1]{1,100}[\u00A1]{1,100}[\u00A1]{1,100}[\u00A1]{1,100}[\u00A1]{1,100}[\u00A1]{1,100}[\u00A1]{1,100}[\u00A1]{1,100}/.exec("\u00A1\u00A1\u00A1\u00A1\u00A1\u00A1\u00A1\u00A1").toString()', '"\u00A1\u00A1\u00A1\u00A1\u00A1\u00A1\u00A1\u00A1"');
     19
    1720debug('');
    1821
Note: See TracChangeset for help on using the changeset viewer.