OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 1665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1676 break; | 1676 break; |
1677 case EXTERNAL_DOUBLE_ARRAY_TYPE: | 1677 case EXTERNAL_DOUBLE_ARRAY_TYPE: |
1678 accumulator->Add("<ExternalDoubleArray[%u]>", | 1678 accumulator->Add("<ExternalDoubleArray[%u]>", |
1679 ExternalDoubleArray::cast(this)->length()); | 1679 ExternalDoubleArray::cast(this)->length()); |
1680 break; | 1680 break; |
1681 case SHARED_FUNCTION_INFO_TYPE: { | 1681 case SHARED_FUNCTION_INFO_TYPE: { |
1682 SharedFunctionInfo* shared = SharedFunctionInfo::cast(this); | 1682 SharedFunctionInfo* shared = SharedFunctionInfo::cast(this); |
1683 SmartArrayPointer<char> debug_name = | 1683 SmartArrayPointer<char> debug_name = |
1684 shared->DebugName()->ToCString(); | 1684 shared->DebugName()->ToCString(); |
1685 if (debug_name[0] != 0) { | 1685 if (debug_name[0] != 0) { |
1686 accumulator->Add("<SharedFunctionInfo %s>", *debug_name); | 1686 accumulator->Add("<SharedFunctionInfo %s>", debug_name.get()); |
1687 } else { | 1687 } else { |
1688 accumulator->Add("<SharedFunctionInfo>"); | 1688 accumulator->Add("<SharedFunctionInfo>"); |
1689 } | 1689 } |
1690 break; | 1690 break; |
1691 } | 1691 } |
1692 case JS_MESSAGE_OBJECT_TYPE: | 1692 case JS_MESSAGE_OBJECT_TYPE: |
1693 accumulator->Add("<JSMessageObject>"); | 1693 accumulator->Add("<JSMessageObject>"); |
1694 break; | 1694 break; |
1695 #define MAKE_STRUCT_CASE(NAME, Name, name) \ | 1695 #define MAKE_STRUCT_CASE(NAME, Name, name) \ |
1696 case NAME##_TYPE: \ | 1696 case NAME##_TYPE: \ |
(...skipping 8209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9906 } | 9906 } |
9907 | 9907 |
9908 | 9908 |
9909 void JSFunction::SetInstanceClassName(String* name) { | 9909 void JSFunction::SetInstanceClassName(String* name) { |
9910 shared()->set_instance_class_name(name); | 9910 shared()->set_instance_class_name(name); |
9911 } | 9911 } |
9912 | 9912 |
9913 | 9913 |
9914 void JSFunction::PrintName(FILE* out) { | 9914 void JSFunction::PrintName(FILE* out) { |
9915 SmartArrayPointer<char> name = shared()->DebugName()->ToCString(); | 9915 SmartArrayPointer<char> name = shared()->DebugName()->ToCString(); |
9916 PrintF(out, "%s", *name); | 9916 PrintF(out, "%s", name.get()); |
9917 } | 9917 } |
9918 | 9918 |
9919 | 9919 |
9920 Context* JSFunction::NativeContextFromLiterals(FixedArray* literals) { | 9920 Context* JSFunction::NativeContextFromLiterals(FixedArray* literals) { |
9921 return Context::cast(literals->get(JSFunction::kLiteralNativeContextIndex)); | 9921 return Context::cast(literals->get(JSFunction::kLiteralNativeContextIndex)); |
9922 } | 9922 } |
9923 | 9923 |
9924 | 9924 |
9925 // The filter is a pattern that matches function names in this way: | 9925 // The filter is a pattern that matches function names in this way: |
9926 // "*" all; the default | 9926 // "*" all; the default |
(...skipping 6724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
16651 #define ERROR_MESSAGES_TEXTS(C, T) T, | 16651 #define ERROR_MESSAGES_TEXTS(C, T) T, |
16652 static const char* error_messages_[] = { | 16652 static const char* error_messages_[] = { |
16653 ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS) | 16653 ERROR_MESSAGES_LIST(ERROR_MESSAGES_TEXTS) |
16654 }; | 16654 }; |
16655 #undef ERROR_MESSAGES_TEXTS | 16655 #undef ERROR_MESSAGES_TEXTS |
16656 return error_messages_[reason]; | 16656 return error_messages_[reason]; |
16657 } | 16657 } |
16658 | 16658 |
16659 | 16659 |
16660 } } // namespace v8::internal | 16660 } } // namespace v8::internal |
OLD | NEW |