summaryrefslogtreecommitdiff
path: root/core/core.js
diff options
context:
space:
mode:
authorAaron O'Mullan <aaron.omullan@gmail.com>2021-05-03 01:30:03 +0200
committerGitHub <noreply@github.com>2021-05-02 19:30:03 -0400
commitea917384feb1c800438d13dddac9ee977d2c47fe (patch)
treee3d5069ac4f96713c98519853cfe25e93c32f883 /core/core.js
parentc9ac851b9005e5a1e90016e52b3a10dd1f1012b7 (diff)
refactor(core): convert core.print() to a builtin op (#10436)
Diffstat (limited to 'core/core.js')
-rw-r--r--core/core.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/core.js b/core/core.js
index e5998fbc8..729ca4faa 100644
--- a/core/core.js
+++ b/core/core.js
@@ -124,6 +124,10 @@
opSync("op_close", rid);
}
+ function print(str, isErr = false) {
+ opSync("op_print", [str, isErr]);
+ }
+
// Provide bootstrap namespace
window.__bootstrap = {};
// Extra Deno.core.* exports
@@ -132,6 +136,7 @@
opSync,
ops,
close,
+ print,
resources,
registerErrorClass,
handleAsyncMsgFromRust,