From 821e17ea9da84522445c8416deda0502890cf7d8 Mon Sep 17 00:00:00 2001
From: ram <ram>
Date: Wed, 1 Apr 1992 15:22:38 +0000
Subject: [PATCH] Apply global function type declarations to calls and
 definitions of global inline functions.

---
 compiler/ir1tran.lisp | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/compiler/ir1tran.lisp b/compiler/ir1tran.lisp
index 21dc8a555..20e81b7a4 100644
--- a/compiler/ir1tran.lisp
+++ b/compiler/ir1tran.lisp
@@ -7,7 +7,7 @@
 ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ir1tran.lisp,v 1.67 1992/03/11 21:23:26 wlott Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/ir1tran.lisp,v 1.68 1992/04/01 15:22:38 ram Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
@@ -507,7 +507,15 @@
 		(if (eq inlinep :inline)
 		    var
 		    fun))
-	  (ir1-convert-combination start cont form fun)))
+	  (let ((res (ir1-convert-combination start cont form fun))
+		(type (leaf-type var))
+		(where-from (leaf-where-from var)))
+	    (when (function-type-p type)
+	      (when (eq where-from :declared)
+		(assert-definition-type fun type
+					:warning-function #'compiler-note
+					:where "previous declaration"))
+	      (assert-call-type res type)))))
       (ir1-convert-ok-combination start cont form var)))
 
 
-- 
GitLab