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

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

Issue 9169063: Add support for native ports in the vm. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 8 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/allocation.cc ('k') | 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 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 // Gets a handle to False 116 // Gets a handle to False
117 static Dart_Handle False(); 117 static Dart_Handle False();
118 118
119 // Allocates space in the local zone. 119 // Allocates space in the local zone.
120 static uword Allocate(intptr_t size); 120 static uword Allocate(intptr_t size);
121 121
122 // Reallocates space in the local zone. 122 // Reallocates space in the local zone.
123 static uword Reallocate(uword ptr, intptr_t old_size, intptr_t new_size); 123 static uword Reallocate(uword ptr, intptr_t old_size, intptr_t new_size);
124 }; 124 };
125 125
126 class IsolateSaver {
127 public:
128 explicit IsolateSaver(Isolate* current_isolate)
129 : saved_isolate_(current_isolate) {
130 }
131 ~IsolateSaver() {
132 Isolate::SetCurrent(saved_isolate_);
133 }
134 private:
135 Isolate* saved_isolate_;
136
137 DISALLOW_COPY_AND_ASSIGN(IsolateSaver);
138 };
139
126 } // namespace dart. 140 } // namespace dart.
127 141
128 #endif // VM_DART_API_IMPL_H_ 142 #endif // VM_DART_API_IMPL_H_
OLDNEW
« no previous file with comments | « runtime/vm/allocation.cc ('k') | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698