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

Side by Side Diff: src/accessors.cc

Issue 1118273004: Migrate error messages, part 8. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 7 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
« no previous file with comments | « no previous file | src/arraybuffer.js » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api.h" 8 #include "src/api.h"
9 #include "src/contexts.h" 9 #include "src/contexts.h"
10 #include "src/deoptimizer.h" 10 #include "src/deoptimizer.h"
11 #include "src/execution.h" 11 #include "src/execution.h"
12 #include "src/factory.h" 12 #include "src/factory.h"
13 #include "src/frames-inl.h" 13 #include "src/frames-inl.h"
14 #include "src/isolate.h" 14 #include "src/isolate.h"
15 #include "src/list-inl.h" 15 #include "src/list-inl.h"
16 #include "src/messages.h"
16 #include "src/property-details.h" 17 #include "src/property-details.h"
17 #include "src/prototype.h" 18 #include "src/prototype.h"
18 19
19 namespace v8 { 20 namespace v8 {
20 namespace internal { 21 namespace internal {
21 22
22 23
23 Handle<AccessorInfo> Accessors::MakeAccessor( 24 Handle<AccessorInfo> Accessors::MakeAccessor(
24 Isolate* isolate, 25 Isolate* isolate,
25 Handle<Name> name, 26 Handle<Name> name,
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 isolate->OptionalRescheduleException(false); 254 isolate->OptionalRescheduleException(false);
254 return; 255 return;
255 } 256 }
256 257
257 if (uint32_v->Number() == number_v->Number()) { 258 if (uint32_v->Number() == number_v->Number()) {
258 maybe = JSArray::SetElementsLength(array_handle, uint32_v); 259 maybe = JSArray::SetElementsLength(array_handle, uint32_v);
259 if (maybe.is_null()) isolate->OptionalRescheduleException(false); 260 if (maybe.is_null()) isolate->OptionalRescheduleException(false);
260 return; 261 return;
261 } 262 }
262 263
263 Handle<Object> exception = isolate->factory()->NewRangeError( 264 Handle<Object> exception =
264 "invalid_array_length", HandleVector<Object>(NULL, 0)); 265 isolate->factory()->NewRangeError(MessageTemplate::kInvalidArrayLength);
265 isolate->ScheduleThrow(*exception); 266 isolate->ScheduleThrow(*exception);
266 } 267 }
267 268
268 269
269 Handle<AccessorInfo> Accessors::ArrayLengthInfo( 270 Handle<AccessorInfo> Accessors::ArrayLengthInfo(
270 Isolate* isolate, PropertyAttributes attributes) { 271 Isolate* isolate, PropertyAttributes attributes) {
271 return MakeAccessor(isolate, 272 return MakeAccessor(isolate,
272 isolate->factory()->length_string(), 273 isolate->factory()->length_string(),
273 &ArrayLengthGetter, 274 &ArrayLengthGetter,
274 &ArrayLengthSetter, 275 &ArrayLengthSetter,
(...skipping 1211 matching lines...) Expand 10 before | Expand all | Expand 10 after
1486 info->set_data(Smi::FromInt(index)); 1487 info->set_data(Smi::FromInt(index));
1487 Handle<Object> getter = v8::FromCData(isolate, &ModuleGetExport); 1488 Handle<Object> getter = v8::FromCData(isolate, &ModuleGetExport);
1488 Handle<Object> setter = v8::FromCData(isolate, &ModuleSetExport); 1489 Handle<Object> setter = v8::FromCData(isolate, &ModuleSetExport);
1489 info->set_getter(*getter); 1490 info->set_getter(*getter);
1490 if (!(attributes & ReadOnly)) info->set_setter(*setter); 1491 if (!(attributes & ReadOnly)) info->set_setter(*setter);
1491 return info; 1492 return info;
1492 } 1493 }
1493 1494
1494 1495
1495 } } // namespace v8::internal 1496 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/arraybuffer.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698