Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/sdks
diff options
context:
space:
mode:
authorKenneth Pouncey <kjpou@pt.lu>2019-10-22 17:05:13 +0300
committerLarry Ewing <lewing@microsoft.com>2019-10-25 20:19:54 +0300
commit1bd76c6069f347a5596d98d40a2a76111639e958 (patch)
tree0dd088c6d332f9800c71e8cff71aad9be18c1beb /sdks
parentf1a3f3c58da220a6e8d462318657dd714e911974 (diff)
Spacing
Diffstat (limited to 'sdks')
-rw-r--r--sdks/wasm/framework/src/WebAssembly.Bindings/Runtime.cs2
-rw-r--r--sdks/wasm/src/corebindings.c6
2 files changed, 0 insertions, 8 deletions
diff --git a/sdks/wasm/framework/src/WebAssembly.Bindings/Runtime.cs b/sdks/wasm/framework/src/WebAssembly.Bindings/Runtime.cs
index 42cd6b0b085..c5e6c50fb2d 100644
--- a/sdks/wasm/framework/src/WebAssembly.Bindings/Runtime.cs
+++ b/sdks/wasm/framework/src/WebAssembly.Bindings/Runtime.cs
@@ -12,10 +12,8 @@ namespace WebAssembly {
public sealed class Runtime {
[MethodImplAttribute (MethodImplOptions.InternalCall)]
static extern string InvokeJS (string str, out int exceptional_result);
-
[MethodImplAttribute (MethodImplOptions.InternalCall)]
static extern object CompileFunction (string str, out int exceptional_result);
-
[MethodImplAttribute (MethodImplOptions.InternalCall)]
internal static extern object InvokeJSWithArgs (int js_obj_handle, string method, object [] _params, out int exceptional_result);
[MethodImplAttribute (MethodImplOptions.InternalCall)]
diff --git a/sdks/wasm/src/corebindings.c b/sdks/wasm/src/corebindings.c
index 8b187ab5aa4..df98336bc45 100644
--- a/sdks/wasm/src/corebindings.c
+++ b/sdks/wasm/src/corebindings.c
@@ -28,7 +28,6 @@ extern MonoObject* mono_wasm_typed_array_copy_from (int js_handle, int ptr, int
// Compiles a JavaScript function from the function data passed.
// Note: code snippet is not a function definition. Instead it must create and return a function instance.
EM_JS(MonoObject*, compile_funtion, (char* snippet, int *is_exception), {
-
try {
var data = UTF8ToString (snippet);
var wrapper = '(function () { ' + data + ' })';
@@ -54,18 +53,13 @@ EM_JS(MonoObject*, compile_funtion, (char* snippet, int *is_exception), {
static MonoObject*
mono_wasm_compile_function (MonoString *str, int *is_exception)
{
-
if (str == NULL)
return NULL;
-
char *native_val = mono_string_to_utf8 (str);
MonoObject* native_res = compile_funtion(native_val, is_exception);
-
mono_free (native_val);
-
if (native_res == NULL)
return NULL;
-
return native_res;
}