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

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

Issue 9166016: Introduce the Error object class in the vm. It represents all of the (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 11 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 | « no previous file | runtime/vm/dart_api_impl.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_DART_API_IMPL_H_ 5 #ifndef VM_DART_API_IMPL_H_
6 #define VM_DART_API_IMPL_H_ 6 #define VM_DART_API_IMPL_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/object.h" 9 #include "vm/object.h"
10 10
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 // Casts the internal Isolate* type to the external Dart_Isolate type. 95 // Casts the internal Isolate* type to the external Dart_Isolate type.
96 static Dart_Isolate CastIsolate(Isolate* isolate); 96 static Dart_Isolate CastIsolate(Isolate* isolate);
97 97
98 // Casts a message byte array to the external Dart_Message type. 98 // Casts a message byte array to the external Dart_Message type.
99 static Dart_Message CastMessage(uint8_t* message); 99 static Dart_Message CastMessage(uint8_t* message);
100 100
101 // Gets the handle used to designate successful return. 101 // Gets the handle used to designate successful return.
102 static Dart_Handle Success(); 102 static Dart_Handle Success();
103 103
104 // Generates a handle used to designate an error return. 104 // Generates a handle used to designate an error return.
105 static Dart_Handle Error(const char* format, ...); 105 static Dart_Handle NewError(const char* format, ...);
106
107 // Generates an error handle from an unhandled exception.
108 static Dart_Handle ErrorFromException(const Object& obj);
109 106
110 // Gets a handle to Null. 107 // Gets a handle to Null.
111 static Dart_Handle Null(); 108 static Dart_Handle Null();
112 109
113 // Gets a handle to True. 110 // Gets a handle to True.
114 static Dart_Handle True(); 111 static Dart_Handle True();
115 112
116 // Gets a handle to False 113 // Gets a handle to False
117 static Dart_Handle False(); 114 static Dart_Handle False();
118 115
119 // Allocates space in the local zone. 116 // Allocates space in the local zone.
120 static uword Allocate(intptr_t size); 117 static uword Allocate(intptr_t size);
121 118
122 // Reallocates space in the local zone. 119 // Reallocates space in the local zone.
123 static uword Reallocate(uword ptr, intptr_t old_size, intptr_t new_size); 120 static uword Reallocate(uword ptr, intptr_t old_size, intptr_t new_size);
124 }; 121 };
125 122
126 } // namespace dart. 123 } // namespace dart.
127 124
128 #endif // VM_DART_API_IMPL_H_ 125 #endif // VM_DART_API_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698