From 2f8d0fca888a42d0553b3880416780bb12f8167c Mon Sep 17 00:00:00 2001 From: Andrea Corallo Date: Sat, 14 Nov 2020 23:22:57 +0100 Subject: [PATCH] * Add more type specifiers * lisp/emacs-lisp/comp.el (comp-known-type-specifiers): Add more pure functions. --- lisp/emacs-lisp/comp.el | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el index da144e4a24f..b8f19b5f586 100644 --- a/lisp/emacs-lisp/comp.el +++ b/lisp/emacs-lisp/comp.el @@ -243,6 +243,35 @@ Useful to hook into pass checkers.") (string< (function ((or string symbol) (or string symbol)) boolean)) (string-lessp (function ((or string symbol) (or string symbol)) boolean)) (string-search (function (string string) (or integer null))) + (string-to-char (function (string) integer)) + (string-to-number (function (string &optional integer) number)) + (string-to-syntax (function (string) cons)) + (substring (function (string &optional integer integer) string)) + (sxhash (function (t) integer)) + (sxhash-equal (function (t) integer)) + (sxhash-eq (function (t) integer)) + (sxhash-eql (function (t) integer)) + (symbol-function (function (symbol) t)) + (symbol-name (function (symbol) string)) + (symbol-plist (function (symbol) list)) + (symbol-value (function (symbol) t)) + (string-make-unibyte (function (string) string)) + (string-make-multibyte (function (string) string)) + (string-as-multibyte (function (string) string)) + (string-as-unibyte (function (string) string)) + (string-to-multibyte (function (string) string)) + (tan (function (number) float)) + (time-convert (function (t &optional (or boolean integer)) cons)) + (truncate (function (number) integer)) + (unibyte-char-to-multibyte (function (fixnum) fixnum)) ;; byte is fixnum + (upcase (function ((or fixnum string)) (or fixnum string))) + (user-full-name (function (&optional integer) string)) + (user-login-name (function (&optional integer) (or string null))) + (user-original-login-name (function (&optional integer) (or string null))) + (custom-variable-p (function (symbol) boolean)) + (vconcat (function (&rest sequence) vector)) + ;; TODO all window-* :x + (zerop (function (number) boolean)) ;; Type hints (comp-hint-fixnum (function (t) fixnum)) (comp-hint-cons (function (t) cons))) -- 2.39.5