diff options
| author | Xander <xander@icth.xyz> | 2023-07-02 15:08:43 +0200 |
|---|---|---|
| committer | Xander <xander@icth.xyz> | 2023-07-02 15:08:43 +0200 |
| commit | d7df4f130521f6005feda56a15f82eb3bf8597dd (patch) | |
| tree | 5781e727a31df75fda53f0f56a104df6cfc01ff6 /kernel/writer.sats | |
| parent | e9b14562b46f230e7208ea3dad8d836f73e8f100 (diff) | |
| download | ats-os-d7df4f130521f6005feda56a15f82eb3bf8597dd.tar.xz ats-os-d7df4f130521f6005feda56a15f82eb3bf8597dd.zip | |
Using reference
Diffstat (limited to 'kernel/writer.sats')
| -rw-r--r-- | kernel/writer.sats | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/writer.sats b/kernel/writer.sats index c9b8814..43881b1 100644 --- a/kernel/writer.sats +++ b/kernel/writer.sats @@ -1,4 +1,4 @@ -#define N 80 * 25 +#define N 2000 datatype color = | Black @@ -21,7 +21,6 @@ datatype color = typedef screenChar = @{ ascii_character = char, color_code = uint8} -vtypedef tptr (a: t@ype, l:addr) = (a @ l | ptr l) -vtypedef writer = [l: addr] [n:nat | n < N] @{ column_position = size_t n, color_code = uint8 , buffer = tptr(@[screenChar][N],l)} +vtypedef writer = [l : agz] @{position = [a:int | a >= 0 && a < N] int (a), color_code = uint8 , buffer = (@[screenChar][N] @ l | ptr l)} fun print_char(c : char) : void |
