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

Side by Side Diff: runtime/vm/object.cc

Issue 237683004: Disable applyAuthorStyles (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/object.h" 5 #include "vm/object.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/cpu.h" 10 #include "vm/cpu.h"
(...skipping 10977 matching lines...) Expand 10 before | Expand all | Expand 10 after
10988 return chars; 10988 return chars;
10989 } 10989 }
10990 10990
10991 10991
10992 RawString* Code::Name() const { 10992 RawString* Code::Name() const {
10993 const Object& obj = Object::Handle(owner()); 10993 const Object& obj = Object::Handle(owner());
10994 if (obj.IsNull()) { 10994 if (obj.IsNull()) {
10995 // Regular stub. 10995 // Regular stub.
10996 const char* name = StubCode::NameOfStub(EntryPoint()); 10996 const char* name = StubCode::NameOfStub(EntryPoint());
10997 ASSERT(name != NULL); 10997 ASSERT(name != NULL);
10998 return String::New(name); 10998 const String& stub_name = String::Handle(String::New(name));
10999 return String::Concat(Symbols::StubPrefix(), stub_name);
10999 } else if (obj.IsClass()) { 11000 } else if (obj.IsClass()) {
11000 // Allocation stub. 11001 // Allocation stub.
11001 const Class& cls = Class::Cast(obj); 11002 const Class& cls = Class::Cast(obj);
11002 String& cls_name = String::Handle(cls.Name()); 11003 String& cls_name = String::Handle(cls.Name());
11003 ASSERT(!cls_name.IsNull()); 11004 ASSERT(!cls_name.IsNull());
11004 return String::Concat(Symbols::AllocationStubFor(), cls_name); 11005 return String::Concat(Symbols::AllocationStubFor(), cls_name);
11005 } else { 11006 } else {
11006 ASSERT(obj.IsFunction()); 11007 ASSERT(obj.IsFunction());
11007 // Dart function. 11008 // Dart function.
11008 return Function::Cast(obj).name(); 11009 return Function::Cast(obj).name();
11009 } 11010 }
11010 } 11011 }
11011 11012
11012 11013
11013 RawString* Code::UserName() const { 11014 RawString* Code::UserName() const {
11014 const Object& obj = Object::Handle(owner()); 11015 const Object& obj = Object::Handle(owner());
11015 if (obj.IsNull()) { 11016 if (obj.IsNull()) {
11016 // Regular stub. 11017 // Regular stub.
11017 const char* name = StubCode::NameOfStub(EntryPoint()); 11018 const char* name = StubCode::NameOfStub(EntryPoint());
11018 ASSERT(name != NULL); 11019 ASSERT(name != NULL);
11019 return String::New(name); 11020 const String& stub_name = String::Handle(String::New(name));
11021 return String::Concat(Symbols::StubPrefix(), stub_name);
11020 } else if (obj.IsClass()) { 11022 } else if (obj.IsClass()) {
11021 // Allocation stub. 11023 // Allocation stub.
11022 const Class& cls = Class::Cast(obj); 11024 const Class& cls = Class::Cast(obj);
11023 String& cls_name = String::Handle(cls.Name()); 11025 String& cls_name = String::Handle(cls.Name());
11024 ASSERT(!cls_name.IsNull()); 11026 ASSERT(!cls_name.IsNull());
11025 return String::Concat(Symbols::AllocationStubFor(), cls_name); 11027 return String::Concat(Symbols::AllocationStubFor(), cls_name);
11026 } else { 11028 } else {
11027 ASSERT(obj.IsFunction()); 11029 ASSERT(obj.IsFunction());
11028 // Dart function. 11030 // Dart function.
11029 return Function::Cast(obj).QualifiedUserVisibleName(); 11031 return Function::Cast(obj).QualifiedUserVisibleName();
(...skipping 7397 matching lines...) Expand 10 before | Expand all | Expand 10 after
18427 return tag_label.ToCString(); 18429 return tag_label.ToCString();
18428 } 18430 }
18429 18431
18430 18432
18431 void UserTag::PrintToJSONStream(JSONStream* stream, bool ref) const { 18433 void UserTag::PrintToJSONStream(JSONStream* stream, bool ref) const {
18432 Instance::PrintToJSONStream(stream, ref); 18434 Instance::PrintToJSONStream(stream, ref);
18433 } 18435 }
18434 18436
18435 18437
18436 } // namespace dart 18438 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698