2021-09-10 16:32:09 +02:00
|
|
|
#![no_std]
|
|
|
|
|
2024-01-12 09:39:38 +01:00
|
|
|
mod modules;
|
2021-12-09 12:32:45 +01:00
|
|
|
mod nanolibc;
|
2021-12-09 00:18:30 +01:00
|
|
|
|
2024-01-13 11:51:44 +01:00
|
|
|
pub mod allocation;
|
2024-01-30 13:56:39 +01:00
|
|
|
pub mod dll;
|
|
|
|
pub mod sys;
|
|
|
|
|
2024-01-12 09:39:38 +01:00
|
|
|
pub use modules::*;
|
2024-01-13 11:51:44 +01:00
|
|
|
|
|
|
|
#[macro_use]
|
|
|
|
extern crate alloc;
|
|
|
|
|
|
|
|
#[macro_export]
|
|
|
|
macro_rules! throw_new {
|
|
|
|
($text:expr) => {
|
|
|
|
debug_write(&format!(
|
|
|
|
"{}:{}\nAn error raised:\n{}\n",
|
|
|
|
file!(),
|
|
|
|
line!(),
|
|
|
|
$text
|
|
|
|
));
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#[macro_export]
|
|
|
|
macro_rules! panic {
|
|
|
|
($text:expr) => {
|
|
|
|
debug_write(cstr_core::cstr!("Panic!\n" + $text + "\n"));
|
2024-01-30 13:56:39 +01:00
|
|
|
unsafe {
|
|
|
|
sys::exit();
|
|
|
|
}
|
2024-01-13 11:51:44 +01:00
|
|
|
};
|
|
|
|
}
|