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

Side by Side Diff: runtime/vm/unit_test.cc

Issue 15772005: - Add different types for persistent and weak persistent handles (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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/object.cc ('k') | no next file » | 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 <stdio.h> 5 #include <stdio.h>
6 6
7 #include "vm/unit_test.h" 7 #include "vm/unit_test.h"
8 8
9 #include "bin/builtin.h" 9 #include "bin/builtin.h"
10 #include "bin/dartutils.h" 10 #include "bin/dartutils.h"
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 return lib; 132 return lib;
133 } 133 }
134 134
135 135
136 Dart_Handle TestCase::library_handler(Dart_LibraryTag tag, 136 Dart_Handle TestCase::library_handler(Dart_LibraryTag tag,
137 Dart_Handle library, 137 Dart_Handle library,
138 Dart_Handle url) { 138 Dart_Handle url) {
139 if (tag == kCanonicalizeUrl) { 139 if (tag == kCanonicalizeUrl) {
140 return url; 140 return url;
141 } 141 }
142 return Api::Success(Isolate::Current()); 142 return Api::Success();
143 } 143 }
144 144
145 145
146 void AssemblerTest::Assemble() { 146 void AssemblerTest::Assemble() {
147 const String& function_name = String::ZoneHandle(Symbols::New(name_)); 147 const String& function_name = String::ZoneHandle(Symbols::New(name_));
148 const Class& cls = Class::ZoneHandle( 148 const Class& cls = Class::ZoneHandle(
149 Class::New(function_name, Script::Handle(), Scanner::kDummyTokenIndex)); 149 Class::New(function_name, Script::Handle(), Scanner::kDummyTokenIndex));
150 Function& function = Function::ZoneHandle( 150 Function& function = Function::ZoneHandle(
151 Function::New(function_name, RawFunction::kRegularFunction, 151 Function::New(function_name, RawFunction::kRegularFunction,
152 true, false, false, false, cls, 0)); 152 true, false, false, false, cls, 0));
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 226
227 bool CompilerTest::TestCompileFunction(const Function& function) { 227 bool CompilerTest::TestCompileFunction(const Function& function) {
228 Isolate* isolate = Isolate::Current(); 228 Isolate* isolate = Isolate::Current();
229 ASSERT(isolate != NULL); 229 ASSERT(isolate != NULL);
230 ASSERT(ClassFinalizer::AllClassesFinalized()); 230 ASSERT(ClassFinalizer::AllClassesFinalized());
231 const Error& error = Error::Handle(Compiler::CompileFunction(function)); 231 const Error& error = Error::Handle(Compiler::CompileFunction(function));
232 return error.IsNull(); 232 return error.IsNull();
233 } 233 }
234 234
235 } // namespace dart 235 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/object.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698