Initial project import
This commit is contained in:
commit
23f2d29e32
11957 files changed
+1754577
No files matched your search
@@ -0,0 +1,21 @@
|
||||
module builtin
|
||||
|
||||
fn JS.__panic_abort(&u8, int)
|
||||
fn JS.__writeln(&u8, int)
|
||||
|
||||
// panic calls the `__panic_abort` JS panic handler.
|
||||
@[noreturn]
|
||||
pub fn panic(s string) {
|
||||
JS.__panic_abort(s.str, s.len)
|
||||
for {}
|
||||
}
|
||||
|
||||
// println prints a message with a line end, to stdout. stdout is flushed.
|
||||
pub fn println(s string) {
|
||||
JS.__writeln(s.str, s.len)
|
||||
}
|
||||
|
||||
// eprintln prints a message with a line end, to the browser output host.
|
||||
pub fn eprintln(s string) {
|
||||
JS.__writeln(s.str, s.len)
|
||||
}
|
||||
Reference in new issue
Block a user