OLD | NEW |
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 #include "vm/exceptions.h" | 5 #include "vm/exceptions.h" |
6 | 6 |
7 #include "vm/cpu.h" | 7 #include "vm/cpu.h" |
8 #include "vm/dart_entry.h" | 8 #include "vm/dart_entry.h" |
9 #include "vm/flags.h" | 9 #include "vm/flags.h" |
10 #include "vm/object.h" | 10 #include "vm/object.h" |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
137 break; | 137 break; |
138 case kObjectNotClosure: | 138 case kObjectNotClosure: |
139 class_name = String::NewSymbol("ObjectNotClosureException"); | 139 class_name = String::NewSymbol("ObjectNotClosureException"); |
140 break; | 140 break; |
141 case kBadNumberFormat: | 141 case kBadNumberFormat: |
142 class_name = String::NewSymbol("BadNumberFormatException"); | 142 class_name = String::NewSymbol("BadNumberFormatException"); |
143 break; | 143 break; |
144 case kStackOverflow: | 144 case kStackOverflow: |
145 class_name = String::NewSymbol("StackOverflowException"); | 145 class_name = String::NewSymbol("StackOverflowException"); |
146 break; | 146 break; |
| 147 case kOutOfMemory: |
| 148 class_name = String::NewSymbol("OutOfMemoryException"); |
| 149 break; |
147 case kWrongArgumentCount: | 150 case kWrongArgumentCount: |
148 class_name = String::NewSymbol("WrongArgumentCountException"); | 151 class_name = String::NewSymbol("WrongArgumentCountException"); |
149 break; | 152 break; |
150 case kInternalError: | 153 case kInternalError: |
151 class_name = String::NewSymbol("InternalError"); | 154 class_name = String::NewSymbol("InternalError"); |
152 break; | 155 break; |
153 case kNullPointer: | 156 case kNullPointer: |
154 class_name = String::NewSymbol("NullPointerException"); | 157 class_name = String::NewSymbol("NullPointerException"); |
155 break; | 158 break; |
156 case kIllegalJSRegExp: | 159 case kIllegalJSRegExp: |
157 class_name = String::NewSymbol("IllegalJSRegExpException"); | 160 class_name = String::NewSymbol("IllegalJSRegExpException"); |
158 break; | 161 break; |
159 } | 162 } |
160 | 163 |
161 return DartLibraryCalls::ExceptionCreate(class_name, arguments); | 164 return DartLibraryCalls::ExceptionCreate(class_name, arguments); |
162 } | 165 } |
163 | 166 |
164 } // namespace dart | 167 } // namespace dart |
OLD | NEW |