From: Stephen Adams Date: Fri, 8 Mar 1996 15:57:43 +0000 (+0000) Subject: Added a warning in DEFINE-OPEN-CODER so warn about primitives that are X-Git-Tag: 20090517-FFI~5664 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=418d9450d257a376d7e6347697001e09bdf4a77b;p=mit-scheme.git Added a warning in DEFINE-OPEN-CODER so warn about primitives that are unknown because if they are introduced before applicat, applicat will insert a %primitive-apply. --- diff --git a/v8/src/compiler/midend/rtlgen.scm b/v8/src/compiler/midend/rtlgen.scm index 5ad17baa1..c7cd56f8e 100644 --- a/v8/src/compiler/midend/rtlgen.scm +++ b/v8/src/compiler/midend/rtlgen.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Id: rtlgen.scm,v 1.41 1995/09/08 16:49:08 adams Exp $ +$Id: rtlgen.scm,v 1.42 1996/03/08 15:57:43 adams Exp $ Copyright (c) 1994-1995 Massachusetts Institute of Technology @@ -2863,9 +2863,15 @@ MIT in each case. |# (define (define-open-coder name-or-object nargs vhandler shandler phandler ohandler sphandler #!optional requires-form?) - (let ((rator (if (known-operator? name-or-object) - name-or-object - (make-primitive-procedure name-or-object nargs)))) + (let ((rator + (if (known-operator? name-or-object) + name-or-object + (let ((prim (make-primitive-procedure name-or-object nargs))) + (if (not (known-operator? prim)) + ;; Applicat makes these into %primitive-apply + (warn "Unknown operator: open coder will never be called" + name-or-object)) + prim)))) (hash-table/put! *open-coders* rator