OLD | NEW |
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 // The infrastructure used for (localized) message reporting in V8. | 5 // The infrastructure used for (localized) message reporting in V8. |
6 // | 6 // |
7 // Note: there's a big unresolved issue about ownership of the data | 7 // Note: there's a big unresolved issue about ownership of the data |
8 // structures used by this framework. | 8 // structures used by this framework. |
9 | 9 |
10 #ifndef V8_MESSAGES_H_ | 10 #ifndef V8_MESSAGES_H_ |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 SKIP_FIRST, | 88 SKIP_FIRST, |
89 // Skip all frames until a specified caller function is seen. | 89 // Skip all frames until a specified caller function is seen. |
90 SKIP_UNTIL_SEEN, | 90 SKIP_UNTIL_SEEN, |
91 SKIP_NONE, | 91 SKIP_NONE, |
92 }; | 92 }; |
93 | 93 |
94 class ErrorUtils : public AllStatic { | 94 class ErrorUtils : public AllStatic { |
95 public: | 95 public: |
96 static MaybeHandle<Object> Construct( | 96 static MaybeHandle<Object> Construct( |
97 Isolate* isolate, Handle<JSFunction> target, Handle<Object> new_target, | 97 Isolate* isolate, Handle<JSFunction> target, Handle<Object> new_target, |
98 Handle<Object> message, FrameSkipMode mode, bool suppress_detailed_trace); | 98 Handle<Object> message, FrameSkipMode mode, Handle<Object> caller, |
| 99 bool suppress_detailed_trace); |
99 | 100 |
100 static MaybeHandle<String> ToString(Isolate* isolate, Handle<Object> recv); | 101 static MaybeHandle<String> ToString(Isolate* isolate, Handle<Object> recv); |
| 102 |
| 103 static MaybeHandle<Object> MakeGenericError( |
| 104 Isolate* isolate, Handle<JSFunction> constructor, int template_index, |
| 105 Handle<Object> arg0, Handle<Object> arg1, Handle<Object> arg2, |
| 106 FrameSkipMode mode); |
101 }; | 107 }; |
102 | 108 |
103 class CallSiteUtils : public AllStatic { | 109 class CallSiteUtils : public AllStatic { |
104 public: | 110 public: |
105 static MaybeHandle<Object> Construct(Isolate* isolate, | 111 static MaybeHandle<Object> Construct(Isolate* isolate, |
106 Handle<Object> receiver, | 112 Handle<Object> receiver, |
107 Handle<Object> fun, Handle<Object> pos, | 113 Handle<Object> fun, Handle<Object> pos, |
108 Handle<Object> strict_mode); | 114 Handle<Object> strict_mode); |
109 | 115 |
110 static MaybeHandle<String> ToString(Isolate* isolate, Handle<Object> recv); | 116 static MaybeHandle<String> ToString(Isolate* isolate, Handle<Object> recv); |
(...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
574 static Handle<String> GetMessage(Isolate* isolate, Handle<Object> data); | 580 static Handle<String> GetMessage(Isolate* isolate, Handle<Object> data); |
575 static std::unique_ptr<char[]> GetLocalizedMessage(Isolate* isolate, | 581 static std::unique_ptr<char[]> GetLocalizedMessage(Isolate* isolate, |
576 Handle<Object> data); | 582 Handle<Object> data); |
577 }; | 583 }; |
578 | 584 |
579 | 585 |
580 } // namespace internal | 586 } // namespace internal |
581 } // namespace v8 | 587 } // namespace v8 |
582 | 588 |
583 #endif // V8_MESSAGES_H_ | 589 #endif // V8_MESSAGES_H_ |
OLD | NEW |