This commit is contained in:
Kartik K. Agaram 2021-04-22 07:56:49 -07:00
parent 4afe53d834
commit 6842dddd68
1 changed files with 9 additions and 2 deletions

View File

@ -82,8 +82,8 @@ fn print-cell _in: (addr handle cell), out: (addr stream byte), trace: (addr tra
}
# debug helper
fn dump-cell in-ah: (addr handle cell) {
var stream-storage: (stream byte 0x40)
fn dump-cell-at-top-right in-ah: (addr handle cell) {
var stream-storage: (stream byte 0x200)
var stream/edx: (addr stream byte) <- address stream-storage
print-cell in-ah, stream, 0/no-trace
var d1/eax: int <- copy 0
@ -91,6 +91,13 @@ fn dump-cell in-ah: (addr handle cell) {
d1, d2 <- draw-stream-wrapping-right-then-down 0/screen, stream, 0/xmin, 0/ymin, 0x80/xmax, 0x30/ymax, 0/x, 0/y, 7/fg, 0/bg
}
fn dump-cell-from-cursor-over-full-screen in-ah: (addr handle cell) {
var stream-storage: (stream byte 0x200)
var stream/edx: (addr stream byte) <- address stream-storage
print-cell in-ah, stream, 0/no-trace
draw-stream-wrapping-right-then-down-from-cursor-over-full-screen 0/screen, stream, 7/fg, 0/bg
}
fn print-symbol _in: (addr cell), out: (addr stream byte), trace: (addr trace) {
trace-text trace, "print", "symbol"
var in/esi: (addr cell) <- copy _in