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

Side by Side Diff: src/object-observe.js

Issue 1099573002: Migrate error messages, part 4 (v8natives.js). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix wrong assertion Created 5 years, 8 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 | « src/messages.js ('k') | src/objects.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 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 var $observeNotifyChange; 5 var $observeNotifyChange;
6 var $observeEnqueueSpliceRecord; 6 var $observeEnqueueSpliceRecord;
7 var $observeBeginPerformSplice; 7 var $observeBeginPerformSplice;
8 var $observeEndPerformSplice; 8 var $observeEndPerformSplice;
9 var $observeNativeObjectObserve; 9 var $observeNativeObjectObserve;
10 var $observeNativeObjectGetNotifier; 10 var $observeNativeObjectGetNotifier;
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 }; 547 };
548 } 548 }
549 549
550 ObjectFreezeJS(changeRecord); 550 ObjectFreezeJS(changeRecord);
551 ObjectInfoEnqueueInternalChangeRecord(objectInfo, changeRecord); 551 ObjectInfoEnqueueInternalChangeRecord(objectInfo, changeRecord);
552 } 552 }
553 553
554 554
555 function ObjectNotifierNotify(changeRecord) { 555 function ObjectNotifierNotify(changeRecord) {
556 if (!IS_SPEC_OBJECT(this)) 556 if (!IS_SPEC_OBJECT(this))
557 throw MakeTypeError("called_on_non_object", ["notify"]); 557 throw MakeTypeError(kCalledOnNonObject, "notify");
558 558
559 var objectInfo = ObjectInfoGetFromNotifier(this); 559 var objectInfo = ObjectInfoGetFromNotifier(this);
560 if (IS_UNDEFINED(objectInfo)) 560 if (IS_UNDEFINED(objectInfo))
561 throw MakeTypeError("observe_notify_non_notifier"); 561 throw MakeTypeError("observe_notify_non_notifier");
562 if (!IS_STRING(changeRecord.type)) 562 if (!IS_STRING(changeRecord.type))
563 throw MakeTypeError("observe_type_non_string"); 563 throw MakeTypeError("observe_type_non_string");
564 564
565 ObjectInfoEnqueueExternalChangeRecord(objectInfo, changeRecord); 565 ObjectInfoEnqueueExternalChangeRecord(objectInfo, changeRecord);
566 } 566 }
567 567
568 568
569 function ObjectNotifierPerformChange(changeType, changeFn) { 569 function ObjectNotifierPerformChange(changeType, changeFn) {
570 if (!IS_SPEC_OBJECT(this)) 570 if (!IS_SPEC_OBJECT(this))
571 throw MakeTypeError("called_on_non_object", ["performChange"]); 571 throw MakeTypeError(kCalledOnNonObject, "performChange");
572 572
573 var objectInfo = ObjectInfoGetFromNotifier(this); 573 var objectInfo = ObjectInfoGetFromNotifier(this);
574 if (IS_UNDEFINED(objectInfo)) 574 if (IS_UNDEFINED(objectInfo))
575 throw MakeTypeError("observe_notify_non_notifier"); 575 throw MakeTypeError("observe_notify_non_notifier");
576 if (!IS_STRING(changeType)) 576 if (!IS_STRING(changeType))
577 throw MakeTypeError("observe_perform_non_string"); 577 throw MakeTypeError("observe_perform_non_string");
578 if (!IS_SPEC_FUNCTION(changeFn)) 578 if (!IS_SPEC_FUNCTION(changeFn))
579 throw MakeTypeError("observe_perform_non_function"); 579 throw MakeTypeError("observe_perform_non_function");
580 580
581 var performChangeFn = %GetObjectContextNotifierPerformChange(objectInfo); 581 var performChangeFn = %GetObjectContextNotifierPerformChange(objectInfo);
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
679 679
680 $observeNotifyChange = NotifyChange; 680 $observeNotifyChange = NotifyChange;
681 $observeEnqueueSpliceRecord = EnqueueSpliceRecord; 681 $observeEnqueueSpliceRecord = EnqueueSpliceRecord;
682 $observeBeginPerformSplice = BeginPerformSplice; 682 $observeBeginPerformSplice = BeginPerformSplice;
683 $observeEndPerformSplice = EndPerformSplice; 683 $observeEndPerformSplice = EndPerformSplice;
684 $observeNativeObjectObserve = NativeObjectObserve; 684 $observeNativeObjectObserve = NativeObjectObserve;
685 $observeNativeObjectGetNotifier = NativeObjectGetNotifier; 685 $observeNativeObjectGetNotifier = NativeObjectGetNotifier;
686 $observeNativeObjectNotifierPerformChange = NativeObjectNotifierPerformChange; 686 $observeNativeObjectNotifierPerformChange = NativeObjectNotifierPerformChange;
687 687
688 })(); 688 })();
OLDNEW
« no previous file with comments | « src/messages.js ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698