diff --git a/compiler/ctype.lisp b/compiler/ctype.lisp
index c3fd0fd62e3a203ae7fa6f3636370c5c21dc0ce7..453e16ab57c5f2b281e564507a39398e78682d4d 100644
--- a/compiler/ctype.lisp
+++ b/compiler/ctype.lisp
@@ -652,7 +652,10 @@
 			  (setq win nil)))))
 		(:required (res (pop req)))
 		(:optional (res (pop opt)))
-		(:rest (res (function-type-rest type))))
+		(:rest
+		 (let ((rest (function-type-rest type)))
+		   (when rest
+		     (res rest)))))
 	      (vars arg)
 	      (when (arg-info-supplied-p info)
 		(res *universal-type*)