| OLD | NEW |
| 1 // Copyright (c) 2014, the Fletch project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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_SHARED_NATIVES_H_ | 5 #ifndef SRC_SHARED_NATIVES_H_ |
| 6 #define SRC_SHARED_NATIVES_H_ | 6 #define SRC_SHARED_NATIVES_H_ |
| 7 | 7 |
| 8 namespace fletch { | 8 namespace fletch { |
| 9 | 9 |
| 10 #define NATIVES_DO(N) \ | 10 #define NATIVES_DO(N) \ |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 N(ProcessDivide, "Process", "_divide") \ | 128 N(ProcessDivide, "Process", "_divide") \ |
| 129 N(ProcessQueueGetMessage, "Process", "_queueGetMessage") \ | 129 N(ProcessQueueGetMessage, "Process", "_queueGetMessage") \ |
| 130 N(ProcessQueueGetChannel, "Process", "_queueGetChannel") \ | 130 N(ProcessQueueGetChannel, "Process", "_queueGetChannel") \ |
| 131 \ | 131 \ |
| 132 N(CoroutineCurrent, "Coroutine", "_coroutineCurrent") \ | 132 N(CoroutineCurrent, "Coroutine", "_coroutineCurrent") \ |
| 133 N(CoroutineNewStack, "Coroutine", "_coroutineNewStack") \ | 133 N(CoroutineNewStack, "Coroutine", "_coroutineNewStack") \ |
| 134 \ | 134 \ |
| 135 N(StopwatchFrequency, "Stopwatch", "_frequency") \ | 135 N(StopwatchFrequency, "Stopwatch", "_frequency") \ |
| 136 N(StopwatchNow, "Stopwatch", "_now") \ | 136 N(StopwatchNow, "Stopwatch", "_now") \ |
| 137 \ | 137 \ |
| 138 N(ForeignLibraryLookup, "ForeignLibrary", "_lookupLibrary") \ |
| 139 N(ForeignLibraryClose, "ForeignLibrary", "_closeLibrary") \ |
| 140 N(ForeignLibraryGetFunction, "ForeignLibrary", "_lookupFunction") \ |
| 141 N(ForeignLibraryBundlePath, "ForeignLibrary", "_bundlePath") \ |
| 142 \ |
| 138 N(ForeignLookup, "Foreign", "_lookup") \ | 143 N(ForeignLookup, "Foreign", "_lookup") \ |
| 139 N(ForeignAllocate, "Foreign", "_allocate") \ | 144 N(ForeignAllocate, "Foreign", "_allocate") \ |
| 140 N(ForeignFree, "Foreign", "_free") \ | 145 N(ForeignFree, "Foreign", "_free") \ |
| 141 N(ForeignMarkForFinalization, "Foreign", "_markForFinalization") \ | 146 N(ForeignMarkForFinalization, "Foreign", "_markForFinalization") \ |
| 142 N(ForeignBitsPerWord, "Foreign", "_bitsPerMachineWord") \ | 147 N(ForeignBitsPerWord, "Foreign", "_bitsPerMachineWord") \ |
| 143 N(ForeignErrno, "Foreign", "_errno") \ | 148 N(ForeignErrno, "Foreign", "_errno") \ |
| 144 N(ForeignPlatform, "Foreign", "_platform") \ | 149 N(ForeignPlatform, "Foreign", "_platform") \ |
| 145 N(ForeignArchitecture, "Foreign", "_architecture") \ | 150 N(ForeignArchitecture, "Foreign", "_architecture") \ |
| 146 N(ForeignConvertPort, "Foreign", "_convertPort") \ | 151 N(ForeignConvertPort, "Foreign", "_convertPort") \ |
| 147 \ | 152 \ |
| (...skipping 28 matching lines...) Expand all Loading... |
| 176 N(ForeignGetUint8, "Foreign", "_getUint8") \ | 181 N(ForeignGetUint8, "Foreign", "_getUint8") \ |
| 177 N(ForeignGetUint16, "Foreign", "_getUint16") \ | 182 N(ForeignGetUint16, "Foreign", "_getUint16") \ |
| 178 N(ForeignGetUint32, "Foreign", "_getUint32") \ | 183 N(ForeignGetUint32, "Foreign", "_getUint32") \ |
| 179 N(ForeignGetUint64, "Foreign", "_getUint64") \ | 184 N(ForeignGetUint64, "Foreign", "_getUint64") \ |
| 180 \ | 185 \ |
| 181 N(ForeignSetUint8, "Foreign", "_setUint8") \ | 186 N(ForeignSetUint8, "Foreign", "_setUint8") \ |
| 182 N(ForeignSetUint16, "Foreign", "_setUint16") \ | 187 N(ForeignSetUint16, "Foreign", "_setUint16") \ |
| 183 N(ForeignSetUint32, "Foreign", "_setUint32") \ | 188 N(ForeignSetUint32, "Foreign", "_setUint32") \ |
| 184 N(ForeignSetUint64, "Foreign", "_setUint64") \ | 189 N(ForeignSetUint64, "Foreign", "_setUint64") \ |
| 185 \ | 190 \ |
| 186 N(ForeignGetFloat32, "Foreign", "_getFloat32") \ | 191 N(ForeignGetFloat32, "Foreign", "_getFloat32") \ |
| 187 N(ForeignGetFloat64, "Foreign", "_getFloat64") \ | 192 N(ForeignGetFloat64, "Foreign", "_getFloat64") \ |
| 188 \ | 193 \ |
| 189 N(ForeignSetFloat32, "Foreign", "_setFloat32") \ | 194 N(ForeignSetFloat32, "Foreign", "_setFloat32") \ |
| 190 N(ForeignSetFloat64, "Foreign", "_setFloat64") \ | 195 N(ForeignSetFloat64, "Foreign", "_setFloat64") \ |
| 191 \ | 196 \ |
| 192 N(StringAdd, "_StringImpl", "+") \ | 197 N(StringAdd, "_StringImpl", "+") \ |
| 193 N(StringCodeUnitAt, "_StringImpl", "codeUnitAt") \ | 198 N(StringCodeUnitAt, "_StringImpl", "codeUnitAt") \ |
| 194 N(StringCreate, "_StringImpl", "_create") \ | 199 N(StringCreate, "_StringImpl", "_create") \ |
| 195 N(StringEqual, "_StringImpl", "==") \ | 200 N(StringEqual, "_StringImpl", "==") \ |
| 196 N(StringLength, "_StringImpl", "length") \ | 201 N(StringLength, "_StringImpl", "length") \ |
| 197 N(StringSetCodeUnitAt, "_StringImpl", "_setCodeUnitAt") \ | 202 N(StringSetCodeUnitAt, "_StringImpl", "_setCodeUnitAt") \ |
| 198 N(StringSubstring, "_StringImpl", "_substring") \ | 203 N(StringSubstring, "_StringImpl", "_substring") \ |
| 199 N(StringToLowerCase, "_StringImpl", "toLowerCase") \ | 204 N(StringToLowerCase, "_StringImpl", "toLowerCase") \ |
| 200 N(StringToUpperCase, "_StringImpl", "toUpperCase") \ | 205 N(StringToUpperCase, "_StringImpl", "toUpperCase") \ |
| (...skipping 15 matching lines...) Expand all Loading... |
| 216 enum Native { | 221 enum Native { |
| 217 #define N(e, c, n) k##e, | 222 #define N(e, c, n) k##e, |
| 218 NATIVES_DO(N) | 223 NATIVES_DO(N) |
| 219 #undef N | 224 #undef N |
| 220 kNumberOfNatives | 225 kNumberOfNatives |
| 221 }; | 226 }; |
| 222 | 227 |
| 223 } // namespace fletch | 228 } // namespace fletch |
| 224 | 229 |
| 225 #endif // SRC_SHARED_NATIVES_H_ | 230 #endif // SRC_SHARED_NATIVES_H_ |
| OLD | NEW |