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

Side by Side Diff: runtime/vm/exceptions.h

Issue 940863002: - Allow any implementation of StackTrace to participate in async/ (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 10 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
« no previous file with comments | « runtime/vm/code_generator.cc ('k') | runtime/vm/exceptions.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 (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 #ifndef VM_EXCEPTIONS_H_ 5 #ifndef VM_EXCEPTIONS_H_
6 #define VM_EXCEPTIONS_H_ 6 #define VM_EXCEPTIONS_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 9
10 namespace dart { 10 namespace dart {
(...skipping 16 matching lines...) Expand all
27 class Stacktrace; 27 class Stacktrace;
28 class String; 28 class String;
29 29
30 class Exceptions : AllStatic { 30 class Exceptions : AllStatic {
31 public: 31 public:
32 static const char* kCastErrorDstName; 32 static const char* kCastErrorDstName;
33 33
34 static void Throw(Isolate* isolate, const Instance& exception); 34 static void Throw(Isolate* isolate, const Instance& exception);
35 static void ReThrow(Isolate* isolate, 35 static void ReThrow(Isolate* isolate,
36 const Instance& exception, 36 const Instance& exception,
37 const Stacktrace& stacktrace); 37 const Instance& stacktrace);
38 static void PropagateError(const Error& error); 38 static void PropagateError(const Error& error);
39 39
40 // Helpers to create and throw errors. 40 // Helpers to create and throw errors.
41 static RawStacktrace* CurrentStacktrace(); 41 static RawStacktrace* CurrentStacktrace();
42 static RawScript* GetCallerScript(DartFrameIterator* iterator); 42 static RawScript* GetCallerScript(DartFrameIterator* iterator);
43 static RawInstance* NewInstance(const char* class_name); 43 static RawInstance* NewInstance(const char* class_name);
44 static void CreateAndThrowTypeError(intptr_t location, 44 static void CreateAndThrowTypeError(intptr_t location,
45 const String& src_type_name, 45 const String& src_type_name,
46 const String& dst_type_name, 46 const String& dst_type_name,
47 const String& dst_name, 47 const String& dst_name,
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 // otherwise returns a RawError. 83 // otherwise returns a RawError.
84 static RawObject* Create(ExceptionType type, const Array& arguments); 84 static RawObject* Create(ExceptionType type, const Array& arguments);
85 85
86 private: 86 private:
87 DISALLOW_COPY_AND_ASSIGN(Exceptions); 87 DISALLOW_COPY_AND_ASSIGN(Exceptions);
88 }; 88 };
89 89
90 } // namespace dart 90 } // namespace dart
91 91
92 #endif // VM_EXCEPTIONS_H_ 92 #endif // VM_EXCEPTIONS_H_
OLDNEW
« no previous file with comments | « runtime/vm/code_generator.cc ('k') | runtime/vm/exceptions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698