Index: runtime/include/dart_api.h |
diff --git a/runtime/include/dart_api.h b/runtime/include/dart_api.h |
index d3f54b1b48ede03ca59aad692b1cbabd5994f12d..fc2576a7bc11c395e1d479847f0764c38ef13a28 100755 |
--- a/runtime/include/dart_api.h |
+++ b/runtime/include/dart_api.h |
@@ -39,6 +39,7 @@ typedef unsigned __int8 uint8_t; |
typedef unsigned __int16 uint16_t; |
typedef unsigned __int32 uint32_t; |
typedef unsigned __int64 uint64_t; |
+#define CHECK_RESULT |
Ivan Posva
2015/08/17 13:35:51
?
zra
2015/08/18 06:23:14
Removed
|
#if defined(DART_SHARED_LIB) |
#define DART_EXPORT DART_EXTERN_C __declspec(dllexport) |
#else |
@@ -368,7 +369,6 @@ DART_EXPORT void _Dart_ReportErrorHandle(const char* file, |
} \ |
} \ |
- |
/** |
* Converts an object to a string. |
* |
@@ -861,9 +861,10 @@ typedef bool (*Dart_EntropySource)(uint8_t* buffer, intptr_t length); |
* \param shutdown A function to be called when an isolate is shutdown. |
* See Dart_IsolateShutdownCallback. |
* |
- * \return True if initialization is successful. |
+ * \return NULL if initialization is successful. Returns an error message |
+ * otherwise. The caller is responsible for freeing the error message. |
*/ |
-DART_EXPORT bool Dart_Initialize( |
+DART_EXPORT char* Dart_Initialize( |
Ivan Posva
2015/08/17 13:35:51
const char*
zra
2015/08/18 06:23:14
See above.
|
const uint8_t* vm_isolate_snapshot, |
Dart_IsolateCreateCallback create, |
Dart_IsolateInterruptCallback interrupt, |
@@ -878,9 +879,10 @@ DART_EXPORT bool Dart_Initialize( |
/** |
* Cleanup state in the VM before process termination. |
* |
- * \return True if cleanup is successful. |
+ * \return NULL if cleanup is successful. Returns an error message otherwise. |
+ * The caller is responsible for freeing the error message. |
*/ |
-DART_EXPORT bool Dart_Cleanup(); |
+DART_EXPORT char* Dart_Cleanup(); |
Ivan Posva
2015/08/17 13:35:51
const char*
zra
2015/08/18 06:23:14
See above.
|
/** |
* Sets command line flags. Should be called before Dart_Initialize. |