Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(176)

Side by Side Diff: test/mjsunit/regress/regress-sliced-external-cons-regexp.js

Issue 368223002: Turn old space cons strings into regular external strings (not short). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: fix assertion Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/objects.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Flags: --expose-externalize-string --expose-gc
6
7 var re = /(B)/;
8 var cons1 = "0123456789" + "ABCDEFGHIJ";
9 var cons2 = "0123456789\u1234" + "ABCDEFGHIJ";
10 gc();
11 gc(); // Promote cons.
12
13 try { externalizeString(cons1, false); } catch (e) { }
14 try { externalizeString(cons2, true); } catch (e) { }
15
16 var slice1 = cons1.slice(1,-1);
17 var slice2 = cons2.slice(1,-1);
18 for (var i = 0; i < 10; i++) {
19 assertEquals(["B", "B"], re.exec(slice1));
20 assertEquals(["B", "B"], re.exec(slice2));
21 }
OLDNEW
« no previous file with comments | « src/objects.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698