From 51d3d7ce39721742aaf673b358b24239be328b45 Mon Sep 17 00:00:00 2001 From: Gabriel Dos Reis Date: Sat, 26 Dec 2015 10:38:16 -0800 Subject: Remove dispatchFunction. --- src/ChangeLog | 9 +++++++++ src/interp/c-util.boot | 4 ++-- src/interp/define.boot | 4 ++-- src/interp/nruncomp.boot | 4 ++-- src/interp/showimp.boot | 4 ++-- src/interp/sys-macros.lisp | 3 --- src/interp/vmlisp.lisp | 2 +- 7 files changed, 18 insertions(+), 12 deletions(-) (limited to 'src') diff --git a/src/ChangeLog b/src/ChangeLog index 4a0368a8..b7c1c482 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,12 @@ +2015-12-26 Gabriel Dos Reis + + * interp/vmlisp.lisp (dispatchFunction): Remove. Adjust users. + * interp/c-util.boot (lookupDefiningFunction): Use opcode + '%function' in lieu of 'dispatchFunction'. + * interp/define.boot (doIt): Likewise. + * interp/nruncomp.boot (descendCodeTran): Likewise. + * interp/showimp.boot (dcOpPrint): Likewise. + 2015-12-25 Gabriel Dos Reis * boot/tokens.boot: Do not rename 'apply'. diff --git a/src/interp/c-util.boot b/src/interp/c-util.boot index 77d0dcca..6256c305 100644 --- a/src/interp/c-util.boot +++ b/src/interp/c-util.boot @@ -1,6 +1,6 @@ -- Copyright (c) 1991-2002, The Numerical Algorithms Group Ltd. -- All rights reserved. --- Copyright (C) 2007-2013, Gabriel Dos Reis. +-- Copyright (C) 2007-2015, Gabriel Dos Reis. -- All rights reserved. -- -- Redistribution and use in source and binary forms, with or without @@ -1767,7 +1767,7 @@ lookupDefiningFunction(op,sig,dc) == -- 6. We have a location to a function descriptor. fun := domainRef(shell,loc) -- 6.1. A constant producing functions? - fun is [.,.,[.,['dispatchFunction,fun'],.]] => fun' + fun is [.,'%constant,[.,['%function,fun'],.]] => fun' -- 6.2. An inherited function? fun is [idx,:.] => not integer? idx => nil -- a UFO? diff --git a/src/interp/define.boot b/src/interp/define.boot index c73b5433..c3813fda 100644 --- a/src/interp/define.boot +++ b/src/interp/define.boot @@ -1,6 +1,6 @@ -- Copyright (c) 1991-2002, The Numerical Algorithms Group Ltd. -- All rights reserved. --- Copyright (C) 2007-2013, Gabriel Dos Reis. +-- Copyright (C) 2007-2015, Gabriel Dos Reis. -- All rights reserved. -- -- Redistribution and use in source and binary forms, with or without @@ -2426,7 +2426,7 @@ doIt(item,$predl) == --Note that DescendCode, in CodeDefine, is looking for this second(item) := [op,$signatureOfForm] --This is how the signature is updated for buildFunctor to recognise - third(item) := ['dispatchFunction,t.expr] + third(item) := ['%function,t.expr] item.rest.rest.rest := nil u := compOrCroak(item,$EmptyMode,$e) => ([code,.,$e]:= u; item.first := first code; item.rest := rest code) diff --git a/src/interp/nruncomp.boot b/src/interp/nruncomp.boot index e35db5a9..3f5d0446 100644 --- a/src/interp/nruncomp.boot +++ b/src/interp/nruncomp.boot @@ -1,6 +1,6 @@ -- Copyright (c) 1991-2002, The Numerical Algorithms Group Ltd. -- All rights reserved. --- Copyright (C) 2007-2013, Gabriel Dos Reis. +-- Copyright (C) 2007-2015, Gabriel Dos Reis. -- All rights reserved. -- -- Redistribution and use in source and binary forms, with or without @@ -339,7 +339,7 @@ descendCodeTran(db,u,condList) == u.rest := nil domainRef(dbTemplate db,i) := fn is '%constant => a - fn is ['dispatchFunction,fn'] => fn' + fn is ['%function,fn'] => fn' fn nil --code for this will be generated by the instantiator u is ['%when,:c] => diff --git a/src/interp/showimp.boot b/src/interp/showimp.boot index a02346fc..8f65d5e5 100644 --- a/src/interp/showimp.boot +++ b/src/interp/showimp.boot @@ -1,6 +1,6 @@ -- Copyright (c) 1991-2002, The Numerical ALgorithms Group Ltd. -- All rights reserved. --- Copyright (C) 2007-2013, Gabriel Dos Reis. +-- Copyright (C) 2007-2015, Gabriel Dos Reis. -- All rights reserved. -- -- Redistribution and use in source and binary forms, with or without @@ -365,7 +365,7 @@ dcOpPrint(op,index) == name := $infovec.0.slotNumber name isnt [.,:.] => name name is ["CONS",'%constant, - ["FUNCALL", ["dispatchFunction", impl],"$"]] => + ["FUNCALL", ['%function, impl],"$"]] => kind := 'CONST impl '"looked up" diff --git a/src/interp/sys-macros.lisp b/src/interp/sys-macros.lisp index 1d5d98bf..301ab9b2 100644 --- a/src/interp/sys-macros.lisp +++ b/src/interp/sys-macros.lisp @@ -231,9 +231,6 @@ (defmacro |function| (name) `(FUNCTION ,name)) -(defmacro |dispatchFunction| (name) - `(FUNCTION ,name)) - (defmacro SPADCALL (&rest L) (let ((args (butlast l)) (fn (car (|lastNode| l))) diff --git a/src/interp/vmlisp.lisp b/src/interp/vmlisp.lisp index bf75f950..d517bc77 100644 --- a/src/interp/vmlisp.lisp +++ b/src/interp/vmlisp.lisp @@ -1,6 +1,6 @@ ;; Copyright (c) 1991-2002, The Numerical Algorithms Group Ltd. ;; All rights reserved. -;; Copyright (C) 2007-2014, Gabriel Dos Reis. +;; Copyright (C) 2007-2015, Gabriel Dos Reis. ;; All rights reserved. ;; ;; Redistribution and use in source and binary forms, with or without -- cgit v1.2.3