Cleans library directory

This commit is contained in:
2026-03-21 21:56:22 +01:00
parent fadecc7c95
commit 897775f63a
14 changed files with 253 additions and 41 deletions

View File

@@ -4,6 +4,5 @@ version = "0.1.0"
edition = "2024"
[dependencies]
# std = { path = "../../crates/std" }
# shared = { path = "../../crates/shared", features = ["user"] }
# core = { path = "../../crates/std/crates/core" }

View File

@@ -1,3 +1,5 @@
// use std::io::_print;
fn main() {
let a = std::env::args();
for a in a {

View File

@@ -1,8 +1,9 @@
#![allow(unused)]
#![feature(panic_internals, core_intrinsics)]
use io::{Read, Write};
use std::io::{Stdin, stdin};
use io::{Read as Readio, Write};
use shared::syscall;
use std::io::{Read, Stdin, stdin};
fn main() {
let mut input = String::new();
@@ -13,10 +14,15 @@ fn main() {
// syscall::sleep(Duration::from_secs_f64(2.0));
syscall::close(0);
let mut tty = syscall::open("/dev/tty0");
syscall::close(1);
let _ = syscall::open("/dev/tty0");
println!("test from test_pic");
tty.write(input.as_bytes()).unwrap();
syscall::spawn("/usr/bin/shell");
core::panicking::panic("explicit panic");
loop {
let mut test = [0; 2];
// let len = stdin().read(&mut test);
let len = tty.read(&mut test).unwrap();
tty.write(str::from_utf8(&test[..len as usize]).unwrap().as_bytes())
.unwrap();