changeset 167:2a35e8c6f67c

add error gear
author anatofuz <anatofuz@cr.ie.u-ryukyu.ac.jp>
date Thu, 16 Jan 2020 16:00:44 +0900
parents a70c436936e4
children 04a5e0aa7f01
files src/impl/kernel_error.h src/interface/ErrorGear.h
diffstat 2 files changed, 10 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/impl/kernel_error.h	Thu Jan 16 16:00:44 2020 +0900
@@ -0,0 +1,2 @@
+typedef struct KernelError <Type, Isa> impl ErrorGear {
+} KernelError;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/interface/ErrorGear.h	Thu Jan 16 16:00:44 2020 +0900
@@ -0,0 +1,8 @@
+typedef struct ErrorGear <Type, Impl> {
+  union Data* error_gear;
+  int err_code;
+  char* msg;
+
+  __code error(int err_code,...);
+  __code panic(char* msg);
+} ErrorGear;