summary refs log tree commit diff
path: root/65c02.ts
diff options
context:
space:
mode:
Diffstat (limited to '65c02.ts')
-rw-r--r--65c02.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/65c02.ts b/65c02.ts
index fb8f050..9805d50 100644
--- a/65c02.ts
+++ b/65c02.ts
@@ -191,7 +191,7 @@ export default class The65c02 {
     /** push stuff onto stack */
     push(val: number) {
         if (this.stackPointer.num() >= 0xFF)
-            throw 'stack overflow (no, not like the website)';
+            console.error('stack overflow (no, not like the website)');
         this.stackPointer.increment();
         this.io.address.set(0x01FF - this.stackPointer.num());
         this.io.data.set(val);
@@ -199,7 +199,7 @@ export default class The65c02 {
     }
     pop(): number {
         if (this.stackPointer.num() <= 0)
-            throw 'stack underflow';
+            console.error('stack underflow');
         this.io.address.set(0x01FF - this.stackPointer.num());
         this.read()
         this.stackPointer.decrement();