From ebe9c8ea14cf92e9eb3bff39afafafbfe50b17bd Mon Sep 17 00:00:00 2001 From: David Schmenk Date: Wed, 9 Aug 2017 13:19:57 -0700 Subject: [PATCH] New portable VM and fix parse typo --- Platform/Apple/tools/PLASMA/src/parse.c | 4 ++-- Platform/Apple/tools/PLASMA/src/plvm.c | 13 +++---------- 2 files changed, 5 insertions(+), 12 deletions(-) diff --git a/Platform/Apple/tools/PLASMA/src/parse.c b/Platform/Apple/tools/PLASMA/src/parse.c index 49a5300b..4b87b334 100644 --- a/Platform/Apple/tools/PLASMA/src/parse.c +++ b/Platform/Apple/tools/PLASMA/src/parse.c @@ -1478,7 +1478,7 @@ int parse_mods(void) emit_moddep(0, 0); return (0); } -iint parse_lambda(void) +int parse_lambda(void) { int func_tag; int cfnparms; @@ -1552,7 +1552,7 @@ iint parse_lambda(void) idlocal_restore(); return (func_tag); } -nt parse_defs(void) +int parse_defs(void) { char c, *idstr; int idlen, func_tag, cfnparms, cfnvals, type = GLOBAL_TYPE, pretype; diff --git a/Platform/Apple/tools/PLASMA/src/plvm.c b/Platform/Apple/tools/PLASMA/src/plvm.c index 9c7ba0c1..62356d6f 100644 --- a/Platform/Apple/tools/PLASMA/src/plvm.c +++ b/Platform/Apple/tools/PLASMA/src/plvm.c @@ -1,12 +1,3 @@ -/* - * Copyright (C) 2015 The 8-Bit Bunch. Licensed under the Apache License, Version 1.1 - * (the "License"); you may not use this file except in compliance with the License. - * You may obtain a copy of the License at . - * Unless required by applicable law or agreed to in writing, software distributed under - * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF - * ANY KIND, either express or implied. See the License for the specific language - * governing permissions and limitations under the License. - */ #include #include #include @@ -785,7 +776,9 @@ void interp(code *ip) fp += PLA; case 0x5C: // RET : IP = TOFP return; - case 0x5E: // ??? + case 0x5E: // CFFB : TOS = CONSTANTBYTE(IP) | 0xFF00 + PUSH(BYTE_PTR(ip) | 0xFF00); + ip++; break; /* * 0x60-0x6F