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

Side by Side Diff: src/vm/ffi.h

Issue 1209033003: Work in progres, please take a look and give early feedback if this is the way we want to structure… (Closed) Base URL: git@github.com:dart-lang/fletch.git@master
Patch Set: remove accidentally added stuff Created 5 years, 5 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
OLDNEW
1 // Copyright (c) 2015, the Fletch project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Fletch 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.md file. 3 // BSD-style license that can be found in the LICENSE.md file.
4 4
5 #ifndef SRC_VM_FFI_H_ 5 #ifndef SRC_VM_FFI_H_
6 #define SRC_VM_FFI_H_ 6 #define SRC_VM_FFI_H_
7 7
8 #include "src/shared/globals.h" 8 #include "src/shared/globals.h"
9 #include "src/shared/natives.h" 9 #include "src/shared/natives.h"
10 10
11 namespace fletch { 11 namespace fletch {
12 12
13 class DefaultLibraryEntry; 13 class DefaultLibraryEntry;
14 class Mutex; 14 class Mutex;
15 15
16 class ForeignFunctionInterface { 16 class ForeignFunctionInterface {
17 public: 17 public:
18 static void Setup(); 18 static void Setup();
19 static void TearDown(); 19 static void TearDown();
20 static void AddDefaultSharedLibrary(const char* library); 20 static void AddDefaultSharedLibrary(const char* library);
21 static void* LookupInDefaultLibraries(const char* symbol); 21 static void* LookupInDefaultLibraries(const char* symbol);
22 private: 22 private:
23 static DefaultLibraryEntry* libraries_; 23 static DefaultLibraryEntry* libraries_;
24 static Mutex* mutex_; 24 static Mutex* mutex_;
25 }; 25 };
26 26
27 // Platform specific ffi constants and methods.
28 class FFIUtils {
29 public:
30 // We construct default bundle library paths from a prefix and a postfix.
31 static const char* kLibBundlePrefix;
32 static const char* kLibBundlePostfix;
33 // In preparation of supporting windows we have a function for this.
34 static char* DirName(char* path);
35 };
36
27 } // namespace fletch 37 } // namespace fletch
28 38
29 #endif // SRC_VM_FFI_H_ 39 #endif // SRC_VM_FFI_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698