diff --git a/src/api-data.coffee b/src/api-data.coffee index 8bb2c146..4a5a67af 100644 --- a/src/api-data.coffee +++ b/src/api-data.coffee @@ -40,5 +40,5 @@ SQLite.TEXT=3 SQLite.BLOB=4 SQLite.NULL=5 -# Encodings, used for registering functions. +# Encodings, used for registering functions. SQLite.UTF8=1 diff --git a/src/api.coffee b/src/api.coffee index e0ca5473..f11ea80e 100644 --- a/src/api.coffee +++ b/src/api.coffee @@ -315,7 +315,7 @@ class Database try # Store the SQL string in memory. The string will be consumed, one statement # at a time, by sqlite3_prepare_v2_sqlptr. - # Note that if we want to allocate as much memory as could _possibly_ be used, we can + # Note that if we want to allocate as much memory as could _possibly_ be used, we can # we allocate bytes equal to 4* the number of chars in the sql string. # It would be faster, but this is probably a premature optimization nextSqlPtr = allocateUTF8OnStack(sql) @@ -484,7 +484,7 @@ class Database sqlite3_result_error(cx,error,-1) return - # Return the result of the user defined function to SQLite + # Return the result of the user defined function to SQLite switch typeof(result) when 'boolean' then sqlite3_result_int(cx,if result then 1 else 0) when 'number' then sqlite3_result_double(cx, result) diff --git a/src/exported_functions.json b/src/exported_functions.json index fe296591..af5085c7 100644 --- a/src/exported_functions.json +++ b/src/exported_functions.json @@ -39,4 +39,4 @@ "_sqlite3_result_int64", "_sqlite3_result_error", "_RegisterExtensionFunctions" -] \ No newline at end of file +] diff --git a/src/exported_runtime_methods.json b/src/exported_runtime_methods.json index c241c3cf..644fd3ea 100644 --- a/src/exported_runtime_methods.json +++ b/src/exported_runtime_methods.json @@ -4,4 +4,3 @@ "stackSave", "stackRestore" ] - diff --git a/src/shell-post.js b/src/shell-post.js index 9122b815..916d4760 100644 --- a/src/shell-post.js +++ b/src/shell-post.js @@ -20,4 +20,3 @@ else if (typeof define === 'function' && define['amd']) { else if (typeof exports === 'object'){ exports["Module"] = initSqlJs; } - diff --git a/src/shell-pre.js b/src/shell-pre.js index 5011ea68..6a4f3ebf 100644 --- a/src/shell-pre.js +++ b/src/shell-pre.js @@ -66,6 +66,6 @@ var initSqlJs = function (moduleConfig) { // of the options, and has the side effect of reducing emcc's efforts to modify the module if its output were to change in the future. // That's a nice side effect since we're handling the modularization efforts ourselves module = undefined; - + // The emcc-generated code and shell-post.js code goes below, // meaning that all of it runs inside of this promise. If anything throws an exception, our promise will abort