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

Side by Side Diff: src/handles.cc

Issue 7710018: Fix typo in assert. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Readded missing test Created 9 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 | « no previous file | src/hydrogen-instructions.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after
610 bool with_last_line) { 610 bool with_last_line) {
611 src = FlattenGetString(src); 611 src = FlattenGetString(src);
612 // Rough estimate of line count based on a roughly estimated average 612 // Rough estimate of line count based on a roughly estimated average
613 // length of (unpacked) code. 613 // length of (unpacked) code.
614 int line_count_estimate = src->length() >> 4; 614 int line_count_estimate = src->length() >> 4;
615 List<int> line_ends(line_count_estimate); 615 List<int> line_ends(line_count_estimate);
616 Isolate* isolate = src->GetIsolate(); 616 Isolate* isolate = src->GetIsolate();
617 { 617 {
618 AssertNoAllocation no_heap_allocation; // ensure vectors stay valid. 618 AssertNoAllocation no_heap_allocation; // ensure vectors stay valid.
619 // Dispatch on type of strings. 619 // Dispatch on type of strings.
620 String::FlatContent content = src->GetFlatContent(no_heap_allocation); 620 String::FlatContent content = src->GetFlatContent();
621 ASSERT(content.IsFlat()); 621 ASSERT(content.IsFlat());
622 if (content.IsAscii()) { 622 if (content.IsAscii()) {
623 CalculateLineEnds(isolate, 623 CalculateLineEnds(isolate,
624 &line_ends, 624 &line_ends,
625 content.ToAsciiVector(), 625 content.ToAsciiVector(),
626 with_last_line); 626 with_last_line);
627 } else { 627 } else {
628 CalculateLineEnds(isolate, 628 CalculateLineEnds(isolate,
629 &line_ends, 629 &line_ends,
630 content.ToUC16Vector(), 630 content.ToUC16Vector(),
(...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after
952 952
953 bool CompileOptimized(Handle<JSFunction> function, 953 bool CompileOptimized(Handle<JSFunction> function,
954 int osr_ast_id, 954 int osr_ast_id,
955 ClearExceptionFlag flag) { 955 ClearExceptionFlag flag) {
956 CompilationInfo info(function); 956 CompilationInfo info(function);
957 info.SetOptimizing(osr_ast_id); 957 info.SetOptimizing(osr_ast_id);
958 return CompileLazyHelper(&info, flag); 958 return CompileLazyHelper(&info, flag);
959 } 959 }
960 960
961 } } // namespace v8::internal 961 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/hydrogen-instructions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698