| 1 |
;;;; -*- Mode: Lisp; Syntax: Common-Lisp; indent-tabs-mode: nil; Package: C -*- |
| 2 |
;;;; vim: set filetype=lisp tabstop=8 shiftwidth=2 expandtab: |
| 3 |
|
| 4 |
;;; |
| 5 |
;;; PROCLAMATIONS of ECL and ANSI Common Lisp functions |
| 6 |
;;; |
| 7 |
;;; Copyright (c) 2010, Juan Jose Garcia Ripoll |
| 8 |
;;; Copying of this file is authorized to users who have executed the true |
| 9 |
;;; and proper "License Agreement for ECL". |
| 10 |
;;; |
| 11 |
;;; The function proclamations are created with PROCLAIM-FUNCTION, as in |
| 12 |
;;; |
| 13 |
;;; (PROCLAMATION function-name ([arg-type]*) return-type |
| 14 |
;;; &rest {:no-sp-change|:pure|:reader|:no-side-effects}) |
| 15 |
;;; |
| 16 |
;;; with the following interpretation: ARG-TYPE and RETURN-TYPE denote the most |
| 17 |
;;; general types for the input and output values of this function. If the |
| 18 |
;;; compiler detects that some of the values passed to this function does not |
| 19 |
;;; match these types, it will generate an error. In addition to this, ECL |
| 20 |
;;; contemplates different function properties: |
| 21 |
;;; |
| 22 |
;;; :NO-SP-CHANGE indicates that the function does not change the value of any |
| 23 |
;;; special variable, and it is used to perform code transformations. |
| 24 |
;;; |
| 25 |
;;; :NO-SIDE-EFFECTS is slightly stronger, as it indicates that the function |
| 26 |
;;; does not change variables or the content of objects in the |
| 27 |
;;; thread environment. Note the following: |
| 28 |
;;; |
| 29 |
;;; - Allocating memory, creating objects, etc is not considered a side |
| 30 |
;;; effect, as it does not affect the code flow. |
| 31 |
;;; - Similarly, signalling errors is not considered a side effect. |
| 32 |
;;; - The environment may be changed by other threads. This is taken |
| 33 |
;;; into account (see below). |
| 34 |
;;; |
| 35 |
;;; :READER indicates that the function not only has no side effects, but its |
| 36 |
;;; value depends only on its arguments. However, :READER specifies that |
| 37 |
;;; the arguments are mutable. |
| 38 |
;;; |
| 39 |
;;; :PURE is the strictest class of functions. They have no side effects, the |
| 40 |
;;; output only depends on the arguments, the arguments are immutable |
| 41 |
;;; objects and the function call can be optimized away when the |
| 42 |
;;; arguments are constant. |
| 43 |
;;; |
| 44 |
|
| 45 |
(in-package "C") |
| 46 |
|
| 47 |
(defun parse-function-proclamation |
| 48 |
(name arg-types return-type &rest properties) |
| 49 |
(when (si:get-sysprop name 'proclaimed-arg-types) |
| 50 |
(warn "Duplicate proclamation for ~A" name)) |
| 51 |
(proclaim-function |
| 52 |
name (list arg-types return-type)) |
| 53 |
(loop for p in properties |
| 54 |
do (case p |
| 55 |
(:no-sp-change |
| 56 |
(si:put-sysprop name 'no-sp-change t)) |
| 57 |
((:predicate :pure) |
| 58 |
(si:put-sysprop name 'pure t) |
| 59 |
(si:put-sysprop name 'no-side-effects t)) |
| 60 |
((:no-side-effects :reader) |
| 61 |
(si:put-sysprop name 'no-side-effects t)) |
| 62 |
(otherwise |
| 63 |
(error "Unknown property ~S in function proclamation for ~S" |
| 64 |
p name))))) |
| 65 |
|
| 66 |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 67 |
;; AUXILIARY TYPES |
| 68 |
;; |
| 69 |
|
| 70 |
(deftype array-rank-index () |
| 71 |
'(integer 0 #.(1- array-rank-limit))) |
| 72 |
(deftype bit-array () |
| 73 |
'(array bit *)) |
| 74 |
(deftype association-list () |
| 75 |
'list |
| 76 |
#+(or) |
| 77 |
'(or null (cons cons association-list))) |
| 78 |
(deftype byte-specifier () |
| 79 |
"The type of the output of BYTE." |
| 80 |
'(cons integer-length integer-length)) |
| 81 |
(deftype character-code () |
| 82 |
'(integer 0 #.(1- char-code-limit))) |
| 83 |
(deftype character-designator () |
| 84 |
'(or character string-designator)) |
| 85 |
(deftype external-file-format () |
| 86 |
'(or symbol list)) |
| 87 |
(deftype declaration-specifier () |
| 88 |
"Element that can appear in a DECLARE form." |
| 89 |
'list) |
| 90 |
(deftype digit-weight () |
| 91 |
'(integer 0 35)) |
| 92 |
(deftype environment () |
| 93 |
"Environment used by compiler and interpreter." |
| 94 |
'list) |
| 95 |
(deftype form () |
| 96 |
"Valid lisp form." |
| 97 |
t) |
| 98 |
(deftype format-control () |
| 99 |
"Format control for FORMAT. It can be a string or a function returned by FORMATTER." |
| 100 |
'(or string function)) |
| 101 |
(deftype function-designator () |
| 102 |
"An object that denotes a function and which can be a symbol or a function." |
| 103 |
'(or symbol function)) |
| 104 |
(deftype function-name () |
| 105 |
"Valid name of a function, typically a symbol or (SETF symbol)." |
| 106 |
'(or list symbol)) |
| 107 |
(deftype gen-bool () |
| 108 |
"Generalized boolean type." |
| 109 |
't) |
| 110 |
(deftype integer-length () |
| 111 |
"A type that fits maximum number of bits that an integer may have in this system." |
| 112 |
'ext:array-index) |
| 113 |
(deftype natural () |
| 114 |
"Non-negative integer." |
| 115 |
'(integer 0 *)) |
| 116 |
(deftype package-designator () |
| 117 |
'(or string-designator package)) |
| 118 |
(deftype pathname-designator () |
| 119 |
'(or pathname string file-stream)) |
| 120 |
(deftype pathname-device () |
| 121 |
'(or string (member nil :unspecific))) |
| 122 |
(deftype pathname-directory () |
| 123 |
'(or string list (member :wild :unspecific))) |
| 124 |
(deftype pathname-host () |
| 125 |
'(or string list (member nil :unspecific))) |
| 126 |
(deftype pathname-name () |
| 127 |
'(or string (member nil :wild :unspecific))) |
| 128 |
(deftype pathname-type () |
| 129 |
'(or string (member nil :wild :unspecific))) |
| 130 |
(deftype pathname-version () |
| 131 |
'(or unsigned-byte (member nil :wild :newest :unspecific))) |
| 132 |
(deftype proper-list () |
| 133 |
'list |
| 134 |
#+(or) |
| 135 |
'(or null (cons t proper-list))) |
| 136 |
(deftype property-list () |
| 137 |
'list |
| 138 |
#+(or) |
| 139 |
'(or null (cons t (cons t property-list)))) |
| 140 |
(deftype radix () |
| 141 |
'(integer 2 36)) |
| 142 |
(deftype readtable-designator () |
| 143 |
'(or null readtable)) |
| 144 |
(deftype restart-designator () |
| 145 |
"Either a symbol naming a restart, or the restart object itself." |
| 146 |
'(or (and symbol (not null)) restart)) |
| 147 |
(deftype sequence-index () |
| 148 |
'(integer 0 #.array-total-size-limit)) |
| 149 |
(deftype stream-designator () |
| 150 |
'(or stream (member t nil))) |
| 151 |
(deftype string-designator () |
| 152 |
'(or symbol string character)) |
| 153 |
(deftype tree () |
| 154 |
't) |
| 155 |
(deftype type-specifier () |
| 156 |
"Name or object representing a type." |
| 157 |
'(or symbol class list)) |
| 158 |
(deftype universal-time () |
| 159 |
"Time represented as a non-negative number of seconds measured from the beginning of 1900." |
| 160 |
'unsigned-byte) |
| 161 |
(deftype time-zone () |
| 162 |
t) |
| 163 |
(deftype ext:instance () |
| 164 |
'standard-object) |
| 165 |
|
| 166 |
(proclaim '(notinline ext:constantp-inner ext:constant-form-value)) |
| 167 |
|
| 168 |
(eval-when (:compile-toplevel :execute) |
| 169 |
(defparameter +proclamations+ '( |
| 170 |
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 171 |
;;; |
| 172 |
;;; ALL FUNCTION DECLARATIONS |
| 173 |
;;; |
| 174 |
;;; |
| 175 |
;;; ANSI SECTIONS |
| 176 |
;;; |
| 177 |
;;; 3. EVALUATION AND COMPILATION |
| 178 |
;;; |
| 179 |
|
| 180 |
(proclamation compile (function-name &optional (or list function)) |
| 181 |
(values (or function-name function) gen-bool gen-bool)) |
| 182 |
(proclamation compiler-macro-function (function-name &optional environment) |
| 183 |
(or function null)) |
| 184 |
(proclamation constantp (t &optional environment) gen-bool) |
| 185 |
(proclamation eval (form) (values &rest t)) |
| 186 |
(proclamation macro-function (symbol &optional environment) (or function null)) |
| 187 |
(proclamation macroexpand (form &optional environment) (values form gen-bool)) |
| 188 |
(proclamation macroexpand-1 (form &optional environment) (values form gen-bool)) |
| 189 |
(proclamation proclaim (declaration-specifier) (values &rest t)) |
| 190 |
(proclamation special-operator-p (symbol) gen-bool :pure) |
| 191 |
|
| 192 |
;; ECL extensions: |
| 193 |
(proclamation si:specialp (symbol) gen-bool :predicate) |
| 194 |
(proclamation si::do-defsetf (symbol (or symbol function) &optional list) t) |
| 195 |
(proclamation si::do-define-setf-method (symbol function) t) |
| 196 |
(proclamation ext:constant-form-value (t &optional environment) t) |
| 197 |
(proclamation ext:constantp-inner (t &optional environment) gen-bool) |
| 198 |
|
| 199 |
(proclamation si::remove-documentation (t) t) |
| 200 |
(proclamation si::find-declarations (t &optional gen-bool) t) |
| 201 |
(proclamation si::search-keyword (t t) t) |
| 202 |
(proclamation si::check-keyword (list list &optional gen-bool) t) |
| 203 |
|
| 204 |
;;; |
| 205 |
;;; 4. TYPES AND CLASSES |
| 206 |
;;; |
| 207 |
|
| 208 |
(proclamation coerce (t type-specifier) t) |
| 209 |
(proclamation subtypep (type-specifier type-specifier &optional environment) |
| 210 |
(values gen-bool gen-bool)) |
| 211 |
(proclamation type-of (t) type-specifier) |
| 212 |
(proclamation typep (t type-specifier &optional environment) gen-bool) |
| 213 |
|
| 214 |
; Slot accessors: |
| 215 |
; (proclamation type-error-datum (condition) t) |
| 216 |
; (proclamation type-error-expected-type (condition) t) |
| 217 |
|
| 218 |
;; ECL EXTENSIONS |
| 219 |
(proclamation si::coerce-to-vector (t type-specifier t gen-bool) vector :no-side-effects) |
| 220 |
(proclamation si::coerce-to-function (function-designator) function :no-side-effects) |
| 221 |
|
| 222 |
;;; |
| 223 |
;;; 5. DATA AND CONTROL FLOW |
| 224 |
;;; |
| 225 |
|
| 226 |
(proclamation apply (function-designator &rest t) (values &rest t)) |
| 227 |
(proclamation fdefinition (function-name) (or list function (member 'SPECIAL)) :reader) |
| 228 |
(proclamation fboundp (function-name) gen-bool :reader) |
| 229 |
(proclamation fmakunbound (function-name) function-name) |
| 230 |
(proclamation funcall (function-designator &rest t) (values &rest t)) |
| 231 |
(proclamation function-lambda-expression (function) (values list gen-bool t) :pure) |
| 232 |
(proclamation functionp (t) gen-bool :pure) |
| 233 |
(proclamation compiled-function-p (t) gen-bool :pure) |
| 234 |
(proclamation not (gen-bool) boolean :pure) |
| 235 |
(proclamation eq (t t) gen-bool :pure) |
| 236 |
(proclamation eql (t t) gen-bool :pure) |
| 237 |
(proclamation equal (t t) gen-bool :pure) |
| 238 |
(proclamation equalp (t t) gen-bool :pure) |
| 239 |
(proclamation identity (t) t) |
| 240 |
(proclamation complement (function) function) |
| 241 |
(proclamation constantly (t) function) |
| 242 |
(proclamation every (function-designator sequence &rest sequence) gen-bool) |
| 243 |
(proclamation some (function-designator sequence &rest sequence) t) |
| 244 |
(proclamation notevery (function-designator sequence &rest sequence) gen-bool) |
| 245 |
(proclamation notany (function-designator sequence &rest sequence) gen-bool) |
| 246 |
(proclamation values-list (list) (values &rest t)) |
| 247 |
(proclamation get-setf-expansion (t &optional environment) (values t t t t t)) |
| 248 |
|
| 249 |
;; ECL extensions |
| 250 |
|
| 251 |
(proclamation si:fset (function-name function &optional gen-bool t) function) |
| 252 |
(proclamation si:setf-definition (function-name createp) list) |
| 253 |
(proclamation ext:compiled-function-name (function) (or null function-name)) |
| 254 |
(proclamation si:compiled-function-block (function) (or null si::codeblock)) |
| 255 |
(proclamation ext:compiled-function-file (function) (values t t)) |
| 256 |
|
| 257 |
(proclamation ext:constantly-t () function) |
| 258 |
|
| 259 |
(proclamation si:ihs-top () si::index) |
| 260 |
(proclamation si:ihs-fun (si::index) (or null function-designator)) |
| 261 |
(proclamation si:ihs-env (si::index) environment) |
| 262 |
(proclamation si:frs-top () si::index) |
| 263 |
(proclamation si:frs-bds (si::index) si::index) |
| 264 |
(proclamation si:frs-tag (si::index) t) |
| 265 |
(proclamation si:frs-ihs (si::index) si::index) |
| 266 |
(proclamation si:bds-top () si::index) |
| 267 |
(proclamation si:bds-var (si::index) symbol) |
| 268 |
(proclamation si:bds-val (si::index) t) |
| 269 |
(proclamation si:sch-frs-base (si::index si::index) (or null si::index)) |
| 270 |
|
| 271 |
(proclamation si::ccase-error (t t t) t) |
| 272 |
(proclamation si::ecase-error (t t) t) |
| 273 |
(proclamation si::etypecase-error (t t) t) |
| 274 |
(proclamation si::ctypecase-error (t t t) t) |
| 275 |
(proclamation si::do-check-type (t t t t) t) |
| 276 |
|
| 277 |
(proclamation si::dm-too-many-arguments (t) t) |
| 278 |
(proclamation si::dm-too-few-arguments (t) t) |
| 279 |
|
| 280 |
;;; |
| 281 |
;;; 7. OBJECTS |
| 282 |
;;; |
| 283 |
|
| 284 |
#+clos |
| 285 |
(proclamation ensure-generic-function (function-name &rest t) generic-function) |
| 286 |
#+clos |
| 287 |
(proclamation slot-boundp (si::instance symbol) gen-bool) |
| 288 |
#+clos |
| 289 |
(proclamation slot-exists-p (si::instance symbol) gen-bool) |
| 290 |
#+clos |
| 291 |
(proclamation slot-makunbound (si::instance symbol) si::instance) |
| 292 |
#+clos |
| 293 |
(proclamation slot-value (si::instance symbol) t) |
| 294 |
#+clos |
| 295 |
(proclamation make-load-form-saving-slots (t &rest t) (values t t)) |
| 296 |
#+clos |
| 297 |
(proclamation find-class (symbol &optional gen-bool environment) |
| 298 |
(or class null)) |
| 299 |
#+clos |
| 300 |
(proclamation class-of (t) class :no-side-effects) |
| 301 |
|
| 302 |
;; Slot accessors: |
| 303 |
; (proclamation unbound-slot-instance (condition) si::instance :predicate) |
| 304 |
|
| 305 |
#+clos |
| 306 |
(proclamation clos::standard-instance-set (ext:instance t t) t) |
| 307 |
#+clos |
| 308 |
(proclamation clos:std-compute-applicable-methods (generic-function list) list) |
| 309 |
#+clos |
| 310 |
(proclamation clos:std-compute-effective-method (generic-function method-combination list) function) |
| 311 |
#+clos |
| 312 |
(proclamation clos:compute-effective-method-function (generic-function method-combination list) function) |
| 313 |
#+clos |
| 314 |
(proclamation clos::update-instance (ext:instance) (values)) |
| 315 |
#+clos |
| 316 |
(proclamation clos::slot-value-set (t si::instance symbol) t) |
| 317 |
#+clos |
| 318 |
(proclamation clos:extract-lambda-list (list) list) |
| 319 |
#+clos |
| 320 |
(proclamation clos:extract-specializer-names (list) list) |
| 321 |
#+clos |
| 322 |
(proclamation clos::install-method (t t t t t &rest t) t) |
| 323 |
#+clos |
| 324 |
(proclamation clos::find-slot-definition (t t) t) |
| 325 |
#+clos |
| 326 |
(proclamation clos::ensure-class (t &rest t) t) |
| 327 |
|
| 328 |
#+(and threads clos) (proclamation mp::compare-and-swap-standard-instance (ext:instance t t t) t) |
| 329 |
#+(and threads clos) (proclamation mp::compare-and-swap-slot-value (ext:instance symbol t t) t) |
| 330 |
#+(and threads clos) (proclamation mp::atomic-incf-standard-instance (ext:instance t fixnum) fixnum) |
| 331 |
#+(and threads clos) (proclamation mp::atomic-incf-slot-value (ext:instance symbol fixnum) fixnum) |
| 332 |
|
| 333 |
;;; |
| 334 |
;;; 8. STRUCTURES |
| 335 |
;;; |
| 336 |
|
| 337 |
(proclamation copy-structure (t) t) |
| 338 |
|
| 339 |
;; ECL extensions |
| 340 |
(proclamation si:make-structure (t &rest t) structure-object) |
| 341 |
(proclamation si:structure-name (structure-object) symbol :reader) |
| 342 |
(proclamation si:structure-ref (structure-object t fixnum) t :reader) |
| 343 |
(proclamation si:structure-set (structure-object t fixnum t) t) |
| 344 |
(proclamation si:structurep (t) gen-bool :predicate) |
| 345 |
(proclamation si:structure-subtype-p (t t) gen-bool :predicate) |
| 346 |
(proclamation si::define-structure (t t t t t t t t t t t t t t t) t) |
| 347 |
(proclamation si::structure-type-error (t t t t) t) |
| 348 |
|
| 349 |
#+threads (proclamation mp:compare-and-swap-structure (structure-object t fixnum t t) t) |
| 350 |
|
| 351 |
;;; |
| 352 |
;;; 9. CONDITIONS |
| 353 |
;;; |
| 354 |
|
| 355 |
(proclamation error (t &rest t) (values)) |
| 356 |
;; FIXME! It is not clear from the specification whether CERROR actually |
| 357 |
;; returns values. However ECL is actually using the fact that it returns |
| 358 |
;; the value from CONTINUE. |
| 359 |
(proclamation cerror (format-control t &rest t) (values &rest t)) |
| 360 |
(proclamation invalid-method-error (method format-control &rest t) (values)) |
| 361 |
(proclamation method-combination-error (format-control &rest t) (values)) |
| 362 |
(proclamation signal (t &rest t) null) |
| 363 |
(proclamation warn (t &rest t) null) |
| 364 |
(proclamation invoke-debugger (condition) (values)) |
| 365 |
(proclamation break (&optional format-control &rest t) null) |
| 366 |
(proclamation make-condition (type-specifier &rest t) condition) |
| 367 |
(proclamation compute-restarts (&optional (or null condition)) list) |
| 368 |
(proclamation find-restart |
| 369 |
(restart-designator &optional (or null condition)) |
| 370 |
(or null restart)) |
| 371 |
(proclamation invoke-restart (restart-designator &rest t) |
| 372 |
(values &rest t)) |
| 373 |
(proclamation invoke-restart-interactively (restart-designator) |
| 374 |
(values &rest t)) |
| 375 |
(proclamation abort (&optional (or null condition)) (values)) |
| 376 |
(proclamation continue (&optional (or null condition)) null) |
| 377 |
(proclamation muffle-warning (&optional (or null condition)) (values)) |
| 378 |
(proclamation store-value (t &optional (or null condition)) null) |
| 379 |
(proclamation use-value (t &optional (or null condition)) null) |
| 380 |
|
| 381 |
;; Slot accessors: |
| 382 |
;; (proclamation cell-error-name (cell-error) t) |
| 383 |
;; (proclamation simple-condition-format-control (simple-condition) t) |
| 384 |
;; (proclamation simple-condition-format-arguments (simple-condition) t) |
| 385 |
;; (proclamation restart-name (restart) t) |
| 386 |
|
| 387 |
;; ECL extensions |
| 388 |
(proclamation ext:catch-signal (fixnum gen-bool &key) null) |
| 389 |
(proclamation si:bind-simple-restarts (t t) list) |
| 390 |
(proclamation si:bind-simple-handlers (t t) list) |
| 391 |
|
| 392 |
;;; |
| 393 |
;;; 10. SYMBOLS |
| 394 |
;;; |
| 395 |
|
| 396 |
(proclamation symbolp (t) gen-bool :pure) |
| 397 |
(proclamation keywordp (t) gen-bool :reader) |
| 398 |
(proclamation make-symbol (string) symbol) |
| 399 |
(proclamation copy-symbol (symbol &optional gen-bool) symbol) |
| 400 |
(proclamation gensym (&optional (or string natural)) symbol) |
| 401 |
(proclamation gentemp (&optional string package-designator) symbol) |
| 402 |
(proclamation symbol-function (symbol) |
| 403 |
(or function list (member 'special)) |
| 404 |
:reader) |
| 405 |
(proclamation symbol-name (symbol) string :pure) |
| 406 |
(proclamation symbol-package (symbol) (or package null) :reader) |
| 407 |
(proclamation symbol-plist (symbol) list :reader) |
| 408 |
(proclamation symbol-value (symbol) t :reader) |
| 409 |
(proclamation get (symbol t &optional t) t :no-side-effects) |
| 410 |
(proclamation remprop (symbol t) gen-bool) |
| 411 |
(proclamation boundp (symbol) gen-bool :reader) |
| 412 |
(proclamation makunbound (symbol) symbol) |
| 413 |
(proclamation set (symbol t) t) |
| 414 |
|
| 415 |
;; ECL extensions: |
| 416 |
(proclamation si:*make-special (symbol) symbol) |
| 417 |
(proclamation si:*make-constant (symbol t) symbol) |
| 418 |
(proclamation si:put-f (list t t) list) |
| 419 |
(proclamation si:rem-f (list t) (values list boolean)) |
| 420 |
(proclamation si:set-symbol-plist (symbol list) list) |
| 421 |
(proclamation si:putprop (symbol t t) t) |
| 422 |
(proclamation si:put-sysprop (t t t) t) |
| 423 |
(proclamation si:get-sysprop (t t) (values t boolean)) |
| 424 |
(proclamation si:rem-sysprop (t t) boolean) |
| 425 |
(proclamation si:put-properties (symbol &rest t) symbol :no-sp-change) |
| 426 |
|
| 427 |
#+threads (proclamation mp:compare-and-swap-symbol-plist (symbol list list) list) |
| 428 |
#+threads (proclamation mp:compare-and-swap-symbol-value (symbol t t) t) |
| 429 |
#+threads (proclamation mp:atomic-incf-symbol-value (symbol fixnum) fixnum) |
| 430 |
|
| 431 |
;;; |
| 432 |
;;; 11. PACKAGES |
| 433 |
;;; |
| 434 |
|
| 435 |
(proclamation export ((or list symbol) &optional package-designator) t) |
| 436 |
(proclamation find-symbol (string &optional package-designator) |
| 437 |
(values symbol (member :inherited :external :internal nil))) |
| 438 |
(proclamation find-package (package-designator) (or package null)) |
| 439 |
(proclamation find-all-symbols (string-designator) list) |
| 440 |
(proclamation import ((or list symbol) &optional package-designator) t) |
| 441 |
(proclamation list-all-packages () list) |
| 442 |
(proclamation rename-package (package-designator package-designator |
| 443 |
&optional list) package) |
| 444 |
(proclamation shadow ((or list string-designator) &optional package-designator) t) |
| 445 |
(proclamation shadowing-import ((or symbol list) &optional package-designator) t) |
| 446 |
(proclamation delete-package (package-designator) gen-bool) |
| 447 |
(proclamation make-package (string-designator &rest t) package) |
| 448 |
(proclamation unexport ((or list symbol) &optional package-designator) t) |
| 449 |
(proclamation unintern (symbol &optional package-designator) gen-bool) |
| 450 |
(proclamation unuse-package (list &optional package-designator) t) |
| 451 |
(proclamation use-package (list &optional package-designator) t) |
| 452 |
(proclamation intern (string &optional package-designator) |
| 453 |
(values symbol (member :inherited :external :internal nil))) |
| 454 |
(proclamation package-name (package-designator) (or string null) :reader) |
| 455 |
(proclamation package-nicknames (package-designator) list :reader) |
| 456 |
(proclamation package-shadowing-symbols (package-designator) list :reader) |
| 457 |
(proclamation package-use-list (package-designator) list :reader) |
| 458 |
(proclamation package-used-by-list (package-designator) list :reader) |
| 459 |
(proclamation packagep (t) gen-bool :pure) |
| 460 |
|
| 461 |
;; Slot accessor: |
| 462 |
;; (proclamation package-error-package (condition) package) |
| 463 |
|
| 464 |
;; ECL extensions |
| 465 |
(proclamation si:select-package (package-designator) package) |
| 466 |
(proclamation si:package-hash-tables (package-designator) |
| 467 |
(values hash-table hash-table list) :reader) |
| 468 |
(proclamation si::packages-iterator (t list gen-bool) function) |
| 469 |
(proclamation ext:package-lock (package-designator gen-bool) package) |
| 470 |
(proclamation ext:package-locked-p (package-designator) boolean :no-side-effects) |
| 471 |
(proclamation ext:package-local-nicknames |
| 472 |
(package-designator) list :no-side-effects) |
| 473 |
(proclamation ext:package-locally-nicknamed-by-list |
| 474 |
(package-designator) list :no-side-effects) |
| 475 |
(proclamation si:%add-package-local-nickname |
| 476 |
(string-designator package-designator package-designator) package) |
| 477 |
(proclamation si:%remove-package-local-nickname |
| 478 |
(string-designator package-designator) list) |
| 479 |
(proclamation ext:add-package-local-nickname |
| 480 |
(string-designator package-designator &optional package-designator) package) |
| 481 |
(proclamation ext:remove-package-local-nickname |
| 482 |
(string-designator &optional package-designator) list) |
| 483 |
|
| 484 |
;;; |
| 485 |
;;; 12. NUMBERS |
| 486 |
;;; |
| 487 |
|
| 488 |
(proclamation = (number &rest number) gen-bool :pure) |
| 489 |
(proclamation /= (number &rest number) gen-bool :pure) |
| 490 |
(proclamation < (real &rest real) gen-bool :pure) |
| 491 |
(proclamation > (real &rest real) gen-bool :pure) |
| 492 |
(proclamation <= (real &rest real) gen-bool :pure) |
| 493 |
(proclamation >= (real &rest real) gen-bool :pure) |
| 494 |
(proclamation max (real &rest real) real :pure) |
| 495 |
(proclamation min (real &rest real) real :pure) |
| 496 |
(proclamation minusp (real) gen-bool :pure) |
| 497 |
(proclamation plusp (real) gen-bool :pure) |
| 498 |
(proclamation zerop (number) gen-bool :pure) |
| 499 |
(proclamation floor (real &optional real) (values integer real) :pure) |
| 500 |
(proclamation ceiling (real &optional real) (values integer real) :pure) |
| 501 |
(proclamation truncate (real &optional real) (values integer real) :pure) |
| 502 |
(proclamation round (real &optional real) (values integer real) :pure) |
| 503 |
(proclamation ffloor (real &optional real) (values float real) :pure) |
| 504 |
(proclamation fceiling (real &optional real) (values float real) :pure) |
| 505 |
(proclamation ftruncate (real &optional real) (values float real) :pure) |
| 506 |
(proclamation fround (real &optional real) (values float real) :pure) |
| 507 |
(proclamation cos (number) number :pure) |
| 508 |
(proclamation sin (number) number :pure) |
| 509 |
(proclamation tan (number) number :pure) |
| 510 |
(proclamation cosh (number) number :pure) |
| 511 |
(proclamation sinh (number) number :pure) |
| 512 |
(proclamation tanh (number) number :pure) |
| 513 |
(proclamation acos (number) number :pure) |
| 514 |
(proclamation asin (number) number :pure) |
| 515 |
(proclamation atan (number &optional real) number :pure) |
| 516 |
(proclamation acosh (number) number :pure) |
| 517 |
(proclamation asinh (number) number :pure) |
| 518 |
(proclamation atanh (number) number :pure) |
| 519 |
(proclamation * (&rest number) number :pure) |
| 520 |
(proclamation + (&rest number) number :pure) |
| 521 |
(proclamation - (&rest number) number :pure) |
| 522 |
(proclamation / (number &rest number) number :pure) |
| 523 |
(proclamation 1+ (number) number :pure) |
| 524 |
(proclamation 1- (number) number :pure) |
| 525 |
(proclamation abs (number) (real 0 *) :pure) |
| 526 |
(proclamation evenp (integer) gen-bool :pure) |
| 527 |
(proclamation oddp (integer) gen-bool :pure) |
| 528 |
(proclamation exp (number) number :pure) |
| 529 |
(proclamation expt (number number) number :pure) |
| 530 |
(proclamation gcd (&rest integer) unsigned-byte :pure) |
| 531 |
(proclamation lcm (&rest integer) unsigned-byte :pure) |
| 532 |
(proclamation log (number &optional number) number :pure) |
| 533 |
(proclamation mod (real real) real :pure) |
| 534 |
(proclamation rem (real real) real :pure) |
| 535 |
(proclamation signum (number) number :pure) |
| 536 |
(proclamation sqrt (number) number :pure) |
| 537 |
(proclamation isqrt (natural) natural :pure) |
| 538 |
(proclamation make-random-state (&optional (or random-state (member nil t))) |
| 539 |
random-state :no-side-effects) |
| 540 |
(proclamation random ((or (integer 0 *) (float 0 *)) &optional random-state) |
| 541 |
(or (integer 0 *) (float 0 *))) |
| 542 |
(proclamation random-state-p (t) gen-bool :pure) |
| 543 |
(proclamation numberp (t) gen-bool :pure) |
| 544 |
(proclamation cis (real) complex :pure) |
| 545 |
(proclamation complex (real &optional real) number :pure) |
| 546 |
(proclamation complexp (t) gen-bool :pure) |
| 547 |
(proclamation conjugate (number) number :pure) |
| 548 |
(proclamation phase (number) (real #.(- pi) #.pi) :pure) |
| 549 |
(proclamation realpart (number) real :pure) |
| 550 |
(proclamation imagpart (number) real :pure) |
| 551 |
(proclamation upgraded-complex-part-type |
| 552 |
(type-specifier &optional environment) |
| 553 |
type-specifier |
| 554 |
:no-side-effects) |
| 555 |
(proclamation realp (t) gen-bool :pure) |
| 556 |
(proclamation numerator (rational) integer :pure) |
| 557 |
(proclamation denominator (rational) unsigned-byte :pure) |
| 558 |
(proclamation rational (real) rational :pure) |
| 559 |
(proclamation rationalize (real) rational :pure) |
| 560 |
(proclamation rationalp (t) gen-bool :pure) |
| 561 |
(proclamation ash (integer integer) integer :pure) |
| 562 |
(proclamation integer-length (integer) integer-length :pure) |
| 563 |
(proclamation integerp (t) gen-bool :pure) |
| 564 |
(proclamation parse-integer (string &rest t) |
| 565 |
(values (or integer null) ext:array-index) |
| 566 |
:no-side-effects) |
| 567 |
(proclamation boole ((integer 0 15) integer integer) integer :pure) |
| 568 |
(proclamation logand (&rest integer) integer :pure) |
| 569 |
(proclamation logandc1 (integer integer) integer :pure) |
| 570 |
(proclamation logandc2 (integer integer) integer :pure) |
| 571 |
(proclamation logeqv (&rest integer) integer :pure) |
| 572 |
(proclamation logior (&rest integer) integer :pure) |
| 573 |
(proclamation lognand (integer integer) integer :pure) |
| 574 |
(proclamation lognor (integer integer) integer :pure) |
| 575 |
(proclamation lognot (integer) integer :pure) |
| 576 |
(proclamation logorc1 (integer integer) integer :pure) |
| 577 |
(proclamation logorc2 (integer integer) integer :pure) |
| 578 |
(proclamation logxor (&rest integer) integer :pure) |
| 579 |
(proclamation logbitp (unsigned-byte integer) gen-bool :pure) |
| 580 |
(proclamation logcount (integer) integer-length :pure) |
| 581 |
(proclamation logtest (integer integer) gen-bool :pure) |
| 582 |
(proclamation byte (unsigned-byte unsigned-byte) byte-specifier :pure) |
| 583 |
(proclamation byte-size (byte-specifier) integer-length :pure) |
| 584 |
(proclamation byte-position (byte-specifier) integer-length :pure) |
| 585 |
(proclamation deposit-field (integer byte-specifier integer) integer :pure) |
| 586 |
(proclamation dpb (integer byte-specifier integer) integer :pure) |
| 587 |
(proclamation ldb (byte-specifier integer) unsigned-byte :pure) |
| 588 |
(proclamation ldb-test (byte-specifier integer) gen-bool :pure) |
| 589 |
(proclamation mask-field (byte-specifier integer) unsigned-byte :pure) |
| 590 |
(proclamation decode-float (float) (values float integer float) :pure) |
| 591 |
(proclamation scale-float (float integer) float :pure) |
| 592 |
(proclamation float-radix (float) fixnum :pure) |
| 593 |
(proclamation float-sign (float &optional float) float :pure) |
| 594 |
(proclamation float-digits (float) |
| 595 |
(integer 0 #.(float-digits (coerce 1.0 'long-float))) |
| 596 |
:pure) |
| 597 |
(proclamation float-precision (float) |
| 598 |
(integer 0 #.(float-digits (coerce 1.0 'long-float))) |
| 599 |
:pure) |
| 600 |
(proclamation integer-decode-float (float) |
| 601 |
(values integer integer (member -1 1)) |
| 602 |
:pure) |
| 603 |
(proclamation float (number &optional float) float :pure) |
| 604 |
(proclamation floatp (t) gen-bool :pure) |
| 605 |
|
| 606 |
;; Slot accessors: |
| 607 |
;; (proclamation arithmetic-error-operands (condition) t) |
| 608 |
;; (proclamation arithmetic-error-operation (condition) t) |
| 609 |
|
| 610 |
;; ECL extensions |
| 611 |
(proclamation si:bit-array-op (t t t t) (array bit)) |
| 612 |
(proclamation ext:fixnump (t) gen-bool :pure) |
| 613 |
(proclamation si:ratiop (t) gen-bool :pure) |
| 614 |
(proclamation si:short-float-p (t) gen-bool :pure) |
| 615 |
(proclamation si:single-float-p (t) gen-bool :pure) |
| 616 |
(proclamation si:double-float-p (t) gen-bool :pure) |
| 617 |
(proclamation si:long-float-p (t) gen-bool :pure) |
| 618 |
#+complex-float (proclamation si:complex-float (float float) si:complex-float :pure) |
| 619 |
#+complex-float (proclamation si:complex-float-p (t) gen-bool :pure) |
| 620 |
|
| 621 |
(proclamation si:single-float-bits (single-float) integer :pure) |
| 622 |
(proclamation si:bits-single-float (integer) single-float :pure) |
| 623 |
(proclamation si:double-float-bits (double-float) integer :pure) |
| 624 |
(proclamation si:bits-double-float (integer) double-float :pure) |
| 625 |
(proclamation si:long-float-bits (long-float) integer :pure) |
| 626 |
(proclamation si:bits-long-float (integer) long-float :pure) |
| 627 |
|
| 628 |
;; Virtual functions added by the compiler |
| 629 |
(proclamation shift>> (*) nil :pure) |
| 630 |
(proclamation shift<< (*) nil :pure) |
| 631 |
(proclamation c::ldb1 (fixnum fixnum fixnum) fixnum :no-side-effects) |
| 632 |
|
| 633 |
|
| 634 |
;;; |
| 635 |
;;; 13. CHARACTERS |
| 636 |
;;; |
| 637 |
|
| 638 |
(proclamation char= (character &rest character) gen-bool :pure) |
| 639 |
(proclamation char/= (character &rest character) gen-bool :pure) |
| 640 |
(proclamation char< (character &rest character) gen-bool :pure) |
| 641 |
(proclamation char> (character &rest character) gen-bool :pure) |
| 642 |
(proclamation char<= (character &rest character) gen-bool :pure) |
| 643 |
(proclamation char>= (character &rest character) gen-bool :pure) |
| 644 |
(proclamation char-equal (character &rest character) gen-bool :pure) |
| 645 |
(proclamation char-not-equal (character &rest character) gen-bool :pure) |
| 646 |
(proclamation char-lessp (character &rest character) gen-bool :pure) |
| 647 |
(proclamation char-greaterp (character &rest character) gen-bool :pure) |
| 648 |
(proclamation char-not-greaterp (character &rest character) gen-bool :pure) |
| 649 |
(proclamation char-not-lessp (character &rest character) gen-bool :pure) |
| 650 |
(proclamation character (character-designator) character) |
| 651 |
(proclamation characterp (t) gen-bool :pure) |
| 652 |
(proclamation alpha-char-p (character) gen-bool :pure) |
| 653 |
(proclamation alphanumericp (character) gen-bool :pure) |
| 654 |
(proclamation digit-char (digit-weight &optional radix) character :pure) |
| 655 |
(proclamation digit-char-p (character &optional radix) |
| 656 |
(or digit-weight null) |
| 657 |
:pure) |
| 658 |
(proclamation graphic-char-p (character) gen-bool :pure) |
| 659 |
(proclamation standard-char-p (character) gen-bool :pure) |
| 660 |
(proclamation char-upcase (character) character :pure) |
| 661 |
(proclamation char-downcase (character) character :pure) |
| 662 |
(proclamation upper-case-p (character) gen-bool :pure) |
| 663 |
(proclamation lower-case-p (character) gen-bool :pure) |
| 664 |
(proclamation both-case-p (character) gen-bool :pure) |
| 665 |
(proclamation char-code (character) character-code :pure) |
| 666 |
(proclamation char-int (character) character-code :pure) |
| 667 |
(proclamation code-char (character-code) (or character null) :pure) |
| 668 |
(proclamation char-name (character) (or string null) :pure) |
| 669 |
(proclamation name-char (string-designator) (or character null) :pure) |
| 670 |
|
| 671 |
;; ECL extensions |
| 672 |
(proclamation si:base-char-p (t) gen-bool :predicate) |
| 673 |
|
| 674 |
;;; |
| 675 |
;;; 14. CONSES |
| 676 |
;;; |
| 677 |
|
| 678 |
(proclamation cons (t t) cons :no-side-effects) |
| 679 |
(proclamation consp (t) gen-bool :pure) |
| 680 |
(proclamation atom (t) gen-bool :pure) |
| 681 |
(proclamation rplaca (cons t) cons) |
| 682 |
(proclamation rplacd (cons t) cons) |
| 683 |
(proclamation car (list) t :reader) |
| 684 |
(proclamation cdr (list) t :reader) |
| 685 |
(proclamation caar (list) t :reader) |
| 686 |
(proclamation cadr (list) t :reader) |
| 687 |
(proclamation cdar (list) t :reader) |
| 688 |
(proclamation cddr (list) t :reader) |
| 689 |
(proclamation caaar (list) t :reader) |
| 690 |
(proclamation caadr (list) t :reader) |
| 691 |
(proclamation cadar (list) t :reader) |
| 692 |
(proclamation caddr (list) t :reader) |
| 693 |
(proclamation cdaar (list) t :reader) |
| 694 |
(proclamation cdadr (list) t :reader) |
| 695 |
(proclamation cddar (list) t :reader) |
| 696 |
(proclamation cdddr (list) t :reader) |
| 697 |
(proclamation caaaar (list) t :reader) |
| 698 |
(proclamation caaadr (list) t :reader) |
| 699 |
(proclamation caadar (list) t :reader) |
| 700 |
(proclamation caaddr (list) t :reader) |
| 701 |
(proclamation cadaar (list) t :reader) |
| 702 |
(proclamation cadadr (list) t :reader) |
| 703 |
(proclamation caddar (list) t :reader) |
| 704 |
(proclamation cadddr (list) t :reader) |
| 705 |
(proclamation cdaaar (list) t :reader) |
| 706 |
(proclamation cdaadr (list) t :reader) |
| 707 |
(proclamation cdadar (list) t :reader) |
| 708 |
(proclamation cdaddr (list) t :reader) |
| 709 |
(proclamation cddaar (list) t :reader) |
| 710 |
(proclamation cddadr (list) t :reader) |
| 711 |
(proclamation cdddar (list) t :reader) |
| 712 |
(proclamation cddddr (list) t :reader) |
| 713 |
(proclamation copy-tree (tree) tree :no-side-effects) |
| 714 |
(proclamation sublis (association-list tree &key) tree) |
| 715 |
(proclamation nsublis (association-list tree &key) tree) |
| 716 |
(proclamation subst (t t tree &key) tree) |
| 717 |
(proclamation subst-if (t function-designator tree &key) tree) |
| 718 |
(proclamation subst-if-not (t function-designator tree &key) tree) |
| 719 |
(proclamation nsubst (t t tree &key) tree) |
| 720 |
(proclamation nsubst-if (t function-designator tree &key) tree) |
| 721 |
(proclamation nsubst-if-not (t function-designator tree &key) tree) |
| 722 |
(proclamation tree-equal (tree tree &key) gen-bool :predicate) |
| 723 |
(proclamation copy-list (list) list :no-side-effects) |
| 724 |
(proclamation list (&rest t) list :no-side-effects) |
| 725 |
(proclamation list* (&rest t) t :no-side-effects) |
| 726 |
(proclamation list-length (list) (or null si::index) :no-side-effects) |
| 727 |
(proclamation listp (t) gen-bool :pure) |
| 728 |
(proclamation make-list (si::index &key) list :no-side-effects) |
| 729 |
(proclamation first (list) t :reader) |
| 730 |
(proclamation second (list) t :reader) |
| 731 |
(proclamation third (list) t :reader) |
| 732 |
(proclamation fourth (list) t :reader) |
| 733 |
(proclamation fifth (list) t :reader) |
| 734 |
(proclamation sixth (list) t :reader) |
| 735 |
(proclamation seventh (list) t :reader) |
| 736 |
(proclamation eighth (list) t :reader) |
| 737 |
(proclamation ninth (list) t :reader) |
| 738 |
(proclamation tenth (list) t :reader) |
| 739 |
(proclamation nth (unsigned-byte list) t :reader) |
| 740 |
(proclamation endp (list) gen-bool :predicate) |
| 741 |
(proclamation null (t) gen-bool :predicate) |
| 742 |
(proclamation nconc (&rest t) t) |
| 743 |
(proclamation append (&rest t) t :no-side-effects) |
| 744 |
(proclamation revappend (list t) t :no-side-effects) |
| 745 |
(proclamation nreconc (list t) t) |
| 746 |
(proclamation butlast (list &optional unsigned-byte) list :no-side-effects) |
| 747 |
(proclamation nbutlast (list &optional unsigned-byte) list) |
| 748 |
(proclamation last (list &optional unsigned-byte) t :reader) |
| 749 |
(proclamation ldiff (list t) list :no-side-effects) |
| 750 |
(proclamation tailp (t list) gen-bool :reader) |
| 751 |
(proclamation nthcdr (fixnum list) t :reader) |
| 752 |
(proclamation rest (list) t :no-side-effects) |
| 753 |
(proclamation member (t proper-list &key) proper-list) |
| 754 |
(proclamation member-if (function-designator proper-list &key) proper-list) |
| 755 |
(proclamation member-if-not (function-designator proper-list &key) |
| 756 |
proper-list) |
| 757 |
(proclamation mapc (function-designator proper-list &rest proper-list) |
| 758 |
proper-list) |
| 759 |
(proclamation mapcar (function-designator proper-list &rest proper-list) |
| 760 |
proper-list) |
| 761 |
(proclamation mapcan (function-designator proper-list &rest proper-list) |
| 762 |
proper-list) |
| 763 |
(proclamation mapl (function-designator proper-list &rest proper-list) |
| 764 |
proper-list) |
| 765 |
(proclamation maplist (function-designator proper-list &rest proper-list) |
| 766 |
proper-list) |
| 767 |
(proclamation mapcon (function-designator proper-list &rest proper-list) |
| 768 |
proper-list) |
| 769 |
(proclamation acons (t t association-list) association-list :no-side-effects) |
| 770 |
(proclamation assoc (t association-list &key) t) |
| 771 |
(proclamation assoc-if (function-designator association-list &key) t) |
| 772 |
(proclamation assoc-if-not (function-designator association-list &key) t) |
| 773 |
(proclamation copy-alist (association-list) association-list :no-side-effects) |
| 774 |
(proclamation pairlis (proper-list proper-list &optional association-list) |
| 775 |
association-list :no-side-effects) |
| 776 |
(proclamation rassoc (t association-list &key) t) |
| 777 |
(proclamation rassoc-if (function-designator association-list &key) t) |
| 778 |
(proclamation rassoc-if-not (function-designator association-list &key) t) |
| 779 |
(proclamation get-properties (property-list proper-list) |
| 780 |
(values t t list) :no-side-effects) |
| 781 |
(proclamation getf (property-list t &optional t) t :reader) |
| 782 |
(proclamation intersection (proper-list proper-list &key) proper-list) |
| 783 |
(proclamation nintersection (proper-list proper-list &key) proper-list) |
| 784 |
(proclamation adjoin (t proper-list &key) proper-list) |
| 785 |
(proclamation set-difference (proper-list proper-list &key) proper-list) |
| 786 |
(proclamation nset-difference (proper-list proper-list &key) proper-list) |
| 787 |
(proclamation set-exclusive-or (proper-list proper-list &key) proper-list) |
| 788 |
(proclamation nset-exclusive-or (proper-list proper-list &key) proper-list) |
| 789 |
(proclamation subsetp (proper-list proper-list &key) gen-bool :predicate) |
| 790 |
(proclamation union (proper-list proper-list &key) proper-list) |
| 791 |
(proclamation nunion (proper-list proper-list &key) proper-list) |
| 792 |
|
| 793 |
;; ECL extensions |
| 794 |
(proclamation si:member1 (t proper-list t t t) list) |
| 795 |
(proclamation si:memq (t proper-list) list) |
| 796 |
(proclamation si:cons-car (cons) t :reader) |
| 797 |
(proclamation si:cons-cdr (cons) t :reader) |
| 798 |
(proclamation si::proper-list-p (t) gen-bool :predicate) |
| 799 |
|
| 800 |
#+threads (proclamation mp:compare-and-swap-car (cons t t) t) |
| 801 |
#+threads (proclamation mp:atomic-incf-car (cons fixnum) fixnum) |
| 802 |
#+threads (proclamation mp:compare-and-swap-cdr (cons t t) t) |
| 803 |
#+threads (proclamation mp:atomic-incf-cdr (cons fixnum) fixnum) |
| 804 |
#+threads (proclamation mp:remcas (symbol) boolean) |
| 805 |
|
| 806 |
;;; |
| 807 |
;;; 15. ARRAYS |
| 808 |
;;; |
| 809 |
|
| 810 |
(proclamation make-array ((or ext:array-index list) &key) |
| 811 |
array :no-side-effects) |
| 812 |
(proclamation adjust-array (array (or ext:array-index list) &key) array) |
| 813 |
(proclamation adjustable-array-p (array) gen-bool :pure) |
| 814 |
(proclamation aref (array &rest ext:array-index) t :reader) |
| 815 |
(proclamation array-dimension (array array-rank-index) |
| 816 |
ext:array-index :reader) |
| 817 |
(proclamation array-dimensions (array) list :reader) |
| 818 |
(proclamation array-element-type (array) type-specifier :pure) |
| 819 |
(proclamation array-has-fill-pointer-p (array) gen-bool :pure) |
| 820 |
(proclamation array-displacement (array) |
| 821 |
(values (or array null) ext:array-index) |
| 822 |
:reader) |
| 823 |
(proclamation array-in-bounds-p (array &rest ext:array-index) gen-bool |
| 824 |
:no-side-effects) |
| 825 |
(proclamation array-rank (array) array-rank-index :reader) |
| 826 |
(proclamation array-row-major-index (array &rest ext:array-index) |
| 827 |
ext:array-index :no-side-effects) |
| 828 |
(proclamation array-total-size (array) ext:array-index :reader) |
| 829 |
(proclamation arrayp (t) gen-bool :pure) |
| 830 |
(proclamation fill-pointer (vector) ext:array-index :reader) |
| 831 |
(proclamation row-major-aref (array ext:array-index) t :reader) |
| 832 |
(proclamation upgraded-array-element-type |
| 833 |
(type-specifier &optional environment) |
| 834 |
type-specifier :no-side-effects) |
| 835 |
(proclamation simple-vector-p (t) gen-bool :pure) |
| 836 |
(proclamation svref (simple-vector ext:array-index) t :reader) |
| 837 |
(proclamation vector (&rest t) vector :no-side-effects) |
| 838 |
(proclamation vector-pop (vector) t) |
| 839 |
(proclamation vector-push (t vector) (or ext:array-index null)) |
| 840 |
(proclamation vector-push-extend (t vector &optional ext:array-index) |
| 841 |
ext:array-index) |
| 842 |
(proclamation vectorp (t) gen-bool :pure) |
| 843 |
(proclamation bit (bit-array &rest ext:array-index) bit :reader) |
| 844 |
(proclamation sbit ((simple-array bit) &rest ext:array-index) |
| 845 |
bit :reader) |
| 846 |
(proclamation bit-and (bit-array bit-array &optional |
| 847 |
(or bit-array (member t nil))) |
| 848 |
bit-array :no-side-effects) |
| 849 |
(proclamation bit-andc1 (bit-array bit-array &optional |
| 850 |
(or bit-array (member t nil))) |
| 851 |
bit-array :no-side-effects) |
| 852 |
(proclamation bit-andc2 (bit-array bit-array &optional |
| 853 |
(or bit-array (member t nil))) |
| 854 |
bit-array :no-side-effects) |
| 855 |
(proclamation bit-eqv (bit-array bit-array &optional |
| 856 |
(or bit-array (member t nil))) |
| 857 |
bit-array :no-side-effects) |
| 858 |
(proclamation bit-ior (bit-array bit-array &optional |
| 859 |
(or bit-array (member t nil))) |
| 860 |
bit-array :no-side-effects) |
| 861 |
(proclamation bit-nand (bit-array bit-array &optional |
| 862 |
(or bit-array (member t nil))) |
| 863 |
bit-array :no-side-effects) |
| 864 |
(proclamation bit-nor (bit-array bit-array &optional |
| 865 |
(or bit-array (member t nil))) |
| 866 |
bit-array :no-side-effects) |
| 867 |
(proclamation bit-orc1 (bit-array bit-array &optional |
| 868 |
(or bit-array (member t nil))) |
| 869 |
bit-array :no-side-effects) |
| 870 |
(proclamation bit-orc2 (bit-array bit-array &optional |
| 871 |
(or bit-array (member t nil))) |
| 872 |
bit-array :no-side-effects) |
| 873 |
(proclamation bit-xor (bit-array bit-array &optional |
| 874 |
(or bit-array (member t nil))) |
| 875 |
bit-array :no-side-effects) |
| 876 |
(proclamation bit-not (bit-array &optional (or bit-array (member t nil))) |
| 877 |
bit-array :no-side-effects) |
| 878 |
(proclamation bit-vector-p (t) gen-bool :pure) |
| 879 |
(proclamation simple-bit-vector-p (t) t :pure) |
| 880 |
|
| 881 |
;; ECL extensions |
| 882 |
(proclamation si:make-pure-array (t t t t t t) array) |
| 883 |
(proclamation si:make-vector (t t t t t t) vector) |
| 884 |
(proclamation si:adjust-vector (vector ext:array-index) vector) |
| 885 |
(proclamation si:aset (array t &rest t) t) |
| 886 |
(proclamation si:row-major-aset (array ext:array-index t) t) |
| 887 |
(proclamation si:svset (simple-vector ext:array-index t) t) |
| 888 |
(proclamation si:fill-pointer-set (vector ext:array-index) ext:array-index) |
| 889 |
(proclamation si:replace-array (array array) array) |
| 890 |
|
| 891 |
#+threads (proclamation mp:compare-and-swap-svref (simple-vector ext:array-index t t) t) |
| 892 |
#+threads (proclamation mp:atomic-incf-svref (simple-vector ext:array-index fixnum) fixnum) |
| 893 |
|
| 894 |
;;; |
| 895 |
;;; 16. STRINGS |
| 896 |
;;; |
| 897 |
|
| 898 |
(proclamation simple-string-p (t) gen-bool :pure) |
| 899 |
(proclamation char (string ext:array-index) character :reader) |
| 900 |
(proclamation schar (simple-string ext:array-index) character :reader) |
| 901 |
(proclamation string (string-designator) string :no-side-effects) |
| 902 |
(proclamation string-upcase (string-designator &key) |
| 903 |
string :no-side-effects) |
| 904 |
(proclamation string-downcase (string-designator &key) |
| 905 |
string :no-side-effects) |
| 906 |
(proclamation string-capitalize (string-designator &key) |
| 907 |
string :no-side-effects) |
| 908 |
(proclamation nstring-upcase (string &key) string) |
| 909 |
(proclamation nstring-downcase (string &key) string) |
| 910 |
(proclamation nstring-capitalize (string &key) string) |
| 911 |
(proclamation string-trim (sequence string-designator) |
| 912 |
string :no-side-effects) |
| 913 |
(proclamation string-left-trim (sequence string-designator) |
| 914 |
string :no-side-effects) |
| 915 |
(proclamation string-right-trim (sequence string-designator) |
| 916 |
string :no-side-effects) |
| 917 |
(proclamation string= (string-designator string-designator &key) |
| 918 |
gen-bool :no-side-effects) |
| 919 |
(proclamation string/= (string-designator string-designator &key) |
| 920 |
(or ext:array-index null) :no-side-effects) |
| 921 |
(proclamation string< (string-designator string-designator &key) |
| 922 |
(or ext:array-index null) :no-side-effects) |
| 923 |
(proclamation string> (string-designator string-designator &key) |
| 924 |
(or ext:array-index null) :no-side-effects) |
| 925 |
(proclamation string<= (string-designator string-designator &key) |
| 926 |
(or ext:array-index null) :no-side-effects) |
| 927 |
(proclamation string>= (string-designator string-designator &key) |
| 928 |
(or ext:array-index null) :no-side-effects) |
| 929 |
(proclamation string-equal (string-designator string-designator &key) |
| 930 |
gen-bool :no-side-effects) |
| 931 |
(proclamation string-not-equal (string-designator string-designator &key) |
| 932 |
(or ext:array-index null) :no-side-effects) |
| 933 |
(proclamation string-lessp (string-designator string-designator &key) |
| 934 |
(or ext:array-index null) :no-side-effects) |
| 935 |
(proclamation string-greaterp (string-designator string-designator &key) |
| 936 |
(or ext:array-index null) :no-side-effects) |
| 937 |
(proclamation string-not-lessp (string-designator string-designator &key) |
| 938 |
(or ext:array-index null) :no-side-effects) |
| 939 |
(proclamation string-not-greaterp (string-designator string-designator &key) |
| 940 |
(or ext:array-index null) :no-side-effects) |
| 941 |
(proclamation stringp (t) gen-bool :predicate) |
| 942 |
(proclamation make-string (ext:array-index &key) string :no-side-effects) |
| 943 |
|
| 944 |
;; ECL extensions: |
| 945 |
(proclamation si:base-string-p (t) gen-bool :pure) |
| 946 |
(proclamation si:char-set (string ext:array-index character) character) |
| 947 |
(proclamation si:schar-set (string ext:array-index character) character) |
| 948 |
(proclamation si:base-string-concatenate (&rest base-string) base-string) |
| 949 |
|
| 950 |
;;; |
| 951 |
;;; 17. SEQUENCES |
| 952 |
;;; |
| 953 |
|
| 954 |
(proclamation copy-seq (sequence) sequence :no-side-effects) |
| 955 |
(proclamation elt (sequence sequence-index) t :no-side-effects) |
| 956 |
(proclamation fill (sequence t &key) sequence) |
| 957 |
(proclamation make-sequence (type-specifier sequence-index &key) |
| 958 |
sequence :no-side-effects) |
| 959 |
(proclamation subseq (sequence sequence-index &optional (or sequence-index null)) |
| 960 |
sequence :no-side-effects) |
| 961 |
(proclamation map (type-specifier function-designator sequence &rest sequence) |
| 962 |
sequence) |
| 963 |
(proclamation map-into (sequence function-designator &rest sequence) |
| 964 |
sequence) |
| 965 |
(proclamation reduce (function-designator sequence &key) t) |
| 966 |
(proclamation count (t sequence &key) sequence-index) |
| 967 |
(proclamation count-if (function-designator sequence &key) sequence-index) |
| 968 |
(proclamation count-if-not (function-designator sequence &key) sequence-index) |
| 969 |
(proclamation length (sequence) sequence-index :no-side-effects) |
| 970 |
(proclamation reverse (sequence) sequence :no-side-effects) |
| 971 |
(proclamation nreverse (sequence) sequence) |
| 972 |
(proclamation sort (sequence function-designator &key) sequence) |
| 973 |
(proclamation stable-sort (sequence function-designator &key) sequence) |
| 974 |
(proclamation find (t sequence &key) t :no-side-effects) |
| 975 |
(proclamation find-if (function-designator sequence &key) t) |
| 976 |
(proclamation find-if-not (function-designator sequence &key) t) |
| 977 |
(proclamation position (t sequence &key) (or null sequence-index)) |
| 978 |
(proclamation position-if (function-designator sequence &key) |
| 979 |
(or null sequence-index)) |
| 980 |
(proclamation position-if-not (function-designator sequence &key) |
| 981 |
(or null sequence-index)) |
| 982 |
(proclamation search (sequence sequence &key) |
| 983 |
(or null sequence-index) :no-side-effects) |
| 984 |
(proclamation mismatch (sequence sequence &key) |
| 985 |
(or null sequence-index) :no-side-effects) |
| 986 |
(proclamation replace (sequence sequence &key) sequence) |
| 987 |
(proclamation substitute (t t sequence &key) sequence) |
| 988 |
(proclamation substitute-if (t function-designator sequence &key) sequence) |
| 989 |
(proclamation substitute-if-not (t function-designator sequence &key) sequence) |
| 990 |
(proclamation nsubstitute (t t sequence &key) sequence) |
| 991 |
(proclamation nsubstitute-if (t function-designator sequence &key) sequence) |
| 992 |
(proclamation nsubstitute-if-not (t function-designator sequence &key) sequence) |
| 993 |
(proclamation concatenate (type-specifier &rest sequence) sequence |
| 994 |
:no-side-effects) |
| 995 |
(proclamation merge (type-specifier sequence sequence function-designator &key) |
| 996 |
sequence) |
| 997 |
(proclamation remove (t sequence &key) sequence) |
| 998 |
(proclamation remove-if (function-designator sequence &key) sequence) |
| 999 |
(proclamation remove-if-not (function-designator sequence &key) sequence) |
| 1000 |
(proclamation delete (t sequence &key) sequence) |
| 1001 |
(proclamation delete-if (function-designator sequence &key) sequence) |
| 1002 |
(proclamation delete-if-not (function-designator sequence &key) sequence) |
| 1003 |
(proclamation remove-duplicates (sequence &key) sequence) |
| 1004 |
(proclamation delete-duplicates (sequence &key) sequence) |
| 1005 |
|
| 1006 |
;; ECL extensions: |
| 1007 |
(proclamation si:elt-set (sequence sequence-index t) t) |
| 1008 |
(proclamation si::make-seq-iterator (sequence &optional sequence-index) |
| 1009 |
t :no-side-effects) |
| 1010 |
(proclamation si::seq-iterator-ref (sequence t) t :reader) |
| 1011 |
(proclamation si::seq-iterator-set (sequence t t) t :no-sp-change) |
| 1012 |
(proclamation si::seq-iterator-next (sequence t) t :reader) |
| 1013 |
(proclamation si::sequence-start-end |
| 1014 |
(t sequence sequence-index (or null sequence-index)) |
| 1015 |
(values fixnum fixnum fixnum) :no-side-effects) |
| 1016 |
(proclamation si::sequence-count ((or null integer)) fixnum :no-side-effects) |
| 1017 |
(proclamation si::coerce-to-list (sequence) list) |
| 1018 |
|
| 1019 |
;;; |
| 1020 |
;;; 18. HASH TABLES |
| 1021 |
;;; |
| 1022 |
|
| 1023 |
(proclamation make-hash-table (&key) hash-table :no-side-effects) |
| 1024 |
(proclamation hash-table-p (t) gen-bool :pure) |
| 1025 |
(proclamation hash-table-count (hash-table) ext:array-index :reader) |
| 1026 |
(proclamation hash-table-rehash-size (hash-table) |
| 1027 |
(or (integer 1 *) (float (1.0) *)) |
| 1028 |
:pure) |
| 1029 |
(proclamation hash-table-rehash-threshold (hash-table) (real 0 1) :pure) |
| 1030 |
(proclamation hash-table-size (hash-table) ext:array-index :reader) |
| 1031 |
(proclamation hash-table-test (hash-table) function-designator :pure) |
| 1032 |
(proclamation gethash (t hash-table &optional t) (values t gen-bool) :reader) |
| 1033 |
(proclamation remhash (t hash-table) gen-bool) |
| 1034 |
(proclamation maphash (function-designator hash-table) null) |
| 1035 |
(proclamation clrhash (hash-table) hash-table) |
| 1036 |
(proclamation sxhash (t) (integer 0 #.most-positive-fixnum) :no-side-effects) |
| 1037 |
|
| 1038 |
;; ECL extensions |
| 1039 |
(proclamation si:hash-set (t hash-table t) t) |
| 1040 |
|
| 1041 |
;;; |
| 1042 |
;;; 19. FILENAMES |
| 1043 |
;;; |
| 1044 |
;;; Note that the pathname interrogation functions could be pure, were it |
| 1045 |
;;; not for the fact that they depend on the environment, as they accept |
| 1046 |
;;; pathname designators, which include strings that should be parsed in |
| 1047 |
;;; that environment. |
| 1048 |
|
| 1049 |
(proclamation pathname (pathname-designator) pathname :no-side-effects) |
| 1050 |
(proclamation make-pathname (&key) pathname :no-side-effects) |
| 1051 |
(proclamation pathnamep (t) gen-bool :pure) |
| 1052 |
(proclamation pathname-host (pathname-designator) pathname-host :no-side-effects) |
| 1053 |
(proclamation pathname-device (pathname-designator) pathname-device :no-side-effects) |
| 1054 |
(proclamation pathname-directory (pathname-designator) pathname-directory :no-side-effects) |
| 1055 |
(proclamation pathname-name (pathname-designator) pathname-name :no-side-effects) |
| 1056 |
(proclamation pathname-type (pathname-designator) pathname-type :no-side-effects) |
| 1057 |
(proclamation pathname-version (pathname-designator) pathname-version :no-side-effects) |
| 1058 |
(proclamation load-logical-pathname-translations (string) gen-bool) |
| 1059 |
(proclamation logical-pathname-translations (string) list) |
| 1060 |
(proclamation logical-pathname (pathname-designator) logical-pathname) |
| 1061 |
(proclamation namestring (pathname-designator) (or string null) |
| 1062 |
:no-side-effects) |
| 1063 |
(proclamation file-namestring (pathname-designator) (or string null) |
| 1064 |
:no-side-effects) |
| 1065 |
(proclamation directory-namestring (pathname-designator) (or string null) |
| 1066 |
:no-side-effects) |
| 1067 |
(proclamation host-namestring (pathname-designator) (or string null) |
| 1068 |
:no-side-effects) |
| 1069 |
(proclamation enough-namestring (pathname-designator &optional pathname-designator) |
| 1070 |
(or string null) |
| 1071 |
:no-side-effects) |
| 1072 |
(proclamation parse-namestring (pathname-designator &optional pathname-host |
| 1073 |
pathname-designator &key) |
| 1074 |
(values (or pathname null) (or ext:array-index null)) |
| 1075 |
:no-side-effects) |
| 1076 |
(proclamation wild-pathname-p (pathname-designator |
| 1077 |
&optional (member :host :device :directory :name |
| 1078 |
:type :version nil)) |
| 1079 |
gen-bool :no-side-effects) |
| 1080 |
(proclamation pathname-match-p (pathname-designator pathname-designator) |
| 1081 |
gen-bool :no-side-effects) |
| 1082 |
(proclamation translate-logical-pathname (pathname-designator &key) pathname |
| 1083 |
:no-side-effects) |
| 1084 |
(proclamation translate-pathname (pathname-designator pathname-designator |
| 1085 |
pathname-designator &key) |
| 1086 |
pathname :no-side-effects) |
| 1087 |
(proclamation merge-pathnames (pathname-designator |
| 1088 |
&optional pathname-designator |
| 1089 |
pathname-version) |
| 1090 |
pathname :no-side-effects) |
| 1091 |
|
| 1092 |
;;; |
| 1093 |
;;; 20. FILES |
| 1094 |
;;; |
| 1095 |
|
| 1096 |
(proclamation directory (pathname-designator &key) list) |
| 1097 |
(proclamation probe-file (pathname-designator) (or pathname null)) |
| 1098 |
(proclamation ensure-directories-exist (pathname-designator &key) |
| 1099 |
(values pathname gen-bool)) |
| 1100 |
(proclamation truename (pathname-designator) pathname) |
| 1101 |
(proclamation file-author (pathname-designator) (or string null)) |
| 1102 |
(proclamation file-write-date (pathname-designator) (or universal-time null)) |
| 1103 |
(proclamation rename-file (pathname-designator pathname-designator) |
| 1104 |
(values pathname pathname pathname)) |
| 1105 |
(proclamation delete-file (pathname-designator) t) |
| 1106 |
|
| 1107 |
;; Slot accessors: |
| 1108 |
;; (proclamation file-error-pathname (condition) pathname-designator) |
| 1109 |
|
| 1110 |
;; ECL extensions |
| 1111 |
(proclamation ext:file-kind (pathname-designator gen-bool) symbol) |
| 1112 |
(proclamation ext:chdir (pathname-designator &optional gen-bool) pathname) |
| 1113 |
(proclamation ext:getcwd (&optional gen-bool) pathname) |
| 1114 |
(proclamation ext:mkstemp (pathname-designator) (or null pathname)) |
| 1115 |
(proclamation ext:copy-file (pathname-designator pathname-designator) gen-bool) |
| 1116 |
|
| 1117 |
(proclamation si:mkdir (pathname-designator unsigned-byte) (or string null)) |
| 1118 |
(proclamation si:rmdir (pathname-designator) null) |
| 1119 |
|
| 1120 |
|
| 1121 |
;;; |
| 1122 |
;;; 21. STREAMS |
| 1123 |
;;; |
| 1124 |
|
| 1125 |
(proclamation input-stream-p (stream) gen-bool :reader) |
| 1126 |
(proclamation output-stream-p (stream) gen-bool :reader) |
| 1127 |
(proclamation interactive-stream-p (stream) gen-bool :reader) |
| 1128 |
(proclamation open-stream-p (stream) gen-bool :reader) |
| 1129 |
(proclamation stream-element-type (stream) type-specifier :reader) |
| 1130 |
(proclamation streamp (t) gen-bool :pure) |
| 1131 |
(proclamation read-byte (stream &optional gen-bool t) t) |
| 1132 |
(proclamation write-byte (integer stream) integer) |
| 1133 |
(proclamation ext:unread-byte (stream integer) null) |
| 1134 |
(proclamation ext:peek-byte (stream t) t) |
| 1135 |
(proclamation peek-char (&optional (or character boolean) |
| 1136 |
stream-designator |
| 1137 |
gen-bool |
| 1138 |
t |
| 1139 |
gen-bool) |
| 1140 |
t) |
| 1141 |
(proclamation read-char (&optional stream-designator gen-bool t gen-bool) t) |
| 1142 |
(proclamation read-char-no-hang (&optional stream-designator gen-bool t gen-bool) t) |
| 1143 |
(proclamation terpri (&optional stream-designator) null) |
| 1144 |
(proclamation fresh-line (&optional stream-designator) gen-bool) |
| 1145 |
(proclamation unread-char (character &optional stream-designator) null) |
| 1146 |
(proclamation write-char (character &optional stream-designator) character) |
| 1147 |
(proclamation read-line (&optional stream-designator gen-bool t gen-bool) |
| 1148 |
(values t gen-bool)) |
| 1149 |
(proclamation write-string (string &optional stream-designator &key) string) |
| 1150 |
(proclamation write-line (string &optional stream-designator &key) string) |
| 1151 |
(proclamation read-sequence (sequence stream &key) sequence-index) |
| 1152 |
(proclamation write-sequence (sequence stream &key) sequence) |
| 1153 |
(proclamation file-length (stream) (or unsigned-byte null)) |
| 1154 |
(proclamation file-position (stream &optional file-position-designator) t) |
| 1155 |
(proclamation file-string-length (stream (or string character)) |
| 1156 |
(or unsigned-byte null)) |
| 1157 |
(proclamation open (pathname-designator &key) (or file-stream null)) |
| 1158 |
(proclamation stream-external-format (stream) external-file-format :reader) |
| 1159 |
(proclamation close (stream &key) t) |
| 1160 |
(proclamation listen (&optional stream-designator) gen-bool) |
| 1161 |
(proclamation clear-input (&optional stream-designator) null) |
| 1162 |
(proclamation finish-output (&optional stream-designator) null) |
| 1163 |
(proclamation force-output (&optional stream-designator) null) |
| 1164 |
(proclamation clear-output (&optional stream-designator) null) |
| 1165 |
(proclamation y-or-n-p (&optional format-control &rest t) gen-bool) |
| 1166 |
(proclamation yes-or-no-p (&optional format-control &rest t) gen-bool) |
| 1167 |
(proclamation make-synonym-stream (symbol) synonym-stream) |
| 1168 |
(proclamation synonym-stream-symbol (synonym-stream) symbol) |
| 1169 |
(proclamation broadcast-stream-streams (broadcast-stream) list :pure) |
| 1170 |
(proclamation make-broadcast-stream (&rest stream) broadcast-stream) |
| 1171 |
(proclamation make-two-way-stream (stream stream) two-way-stream) |
| 1172 |
(proclamation two-way-stream-input-stream (two-way-stream) stream :pure) |
| 1173 |
(proclamation two-way-stream-output-stream (two-way-stream) stream :pure) |
| 1174 |
(proclamation echo-stream-output-stream (echo-stream) stream :pure) |
| 1175 |
(proclamation echo-stream-input-stream (echo-stream) stream :pure) |
| 1176 |
(proclamation make-echo-stream (stream stream) echo-stream) |
| 1177 |
(proclamation concatenated-stream-streams (concatenated-stream) |
| 1178 |
list :reader) |
| 1179 |
(proclamation make-concatenated-stream (&rest stream) |
| 1180 |
concatenated-stream) |
| 1181 |
(proclamation get-output-stream-string (string-stream) string :reader) |
| 1182 |
(proclamation make-string-input-stream (string &optional |
| 1183 |
ext:array-index |
| 1184 |
(or ext:array-index null)) |
| 1185 |
string-stream :reader) |
| 1186 |
(proclamation make-string-output-stream (&key) string-stream :reader) |
| 1187 |
|
| 1188 |
;; Slot accessors: |
| 1189 |
;; (proclamation stream-error-stream (condition) stream) |
| 1190 |
|
| 1191 |
;; ECL extensions: |
| 1192 |
(proclamation si:make-string-output-stream-from-string (string) |
| 1193 |
string-stream :reader) |
| 1194 |
#+wants-sockets |
| 1195 |
(proclamation si:open-client-stream (t unsigned-byte) stream) |
| 1196 |
#+wants-sockets |
| 1197 |
(proclamation si:open-server-stream (unsigned-byte) stream) |
| 1198 |
#+wants-sockets |
| 1199 |
(proclamation si:open-unix-socket-stream (string) stream) |
| 1200 |
#+wants-sockets |
| 1201 |
(proclamation si:lookup-host-entry (t) (values (or null string) list list)) |
| 1202 |
(proclamation si:copy-stream (stream stream gen-bool) t) |
| 1203 |
(proclamation si:make-encoding (t) hash-table) |
| 1204 |
(proclamation si:load-encoding (t) t) |
| 1205 |
|
| 1206 |
;;; |
| 1207 |
;;; 22. PRINT |
| 1208 |
;;; |
| 1209 |
|
| 1210 |
(proclamation copy-pprint-dispatch (&optional (or si::pprint-dispatch-table null)) |
| 1211 |
si::pprint-dispatch-table |
| 1212 |
:no-side-effects) |
| 1213 |
(proclamation pprint-dispatch (t &optional (or si::pprint-dispatch-table null)) |
| 1214 |
(values function-designator gen-bool)) |
| 1215 |
(proclamation pprint-fill (stream-designator t &optional gen-bool gen-bool) |
| 1216 |
null) |
| 1217 |
(proclamation pprint-linear (stream-designator t &optional gen-bool gen-bool) |
| 1218 |
null) |
| 1219 |
(proclamation pprint-tabular (stream-designator t &optional gen-bool gen-bool |
| 1220 |
unsigned-byte) |
| 1221 |
null) |
| 1222 |
(proclamation pprint-indent ((member :block :current) real |
| 1223 |
&optional stream-designator) |
| 1224 |
null) |
| 1225 |
(proclamation pprint-newline ((member :linear :fill :miser :mandatory) |
| 1226 |
&optional stream-designator) |
| 1227 |
null) |
| 1228 |
(proclamation pprint-tab ((member :line :section :line-relative :section-relative) |
| 1229 |
unsigned-byte unsigned-byte &optional stream-designator) |
| 1230 |
null) |
| 1231 |
(proclamation set-pprint-dispatch (type-specifier |
| 1232 |
(or function-designator null) |
| 1233 |
&optional real si::pprint-dispatch-table) |
| 1234 |
null) |
| 1235 |
(proclamation write (t &key) t) |
| 1236 |
(proclamation prin1 (t &optional stream-designator) t) |
| 1237 |
(proclamation princ (t &optional stream-designator) t) |
| 1238 |
(proclamation print (t &optional stream-designator) t) |
| 1239 |
(proclamation pprint (t &optional stream-designator) (values)) |
| 1240 |
(proclamation write-to-string (t &key) string) |
| 1241 |
(proclamation prin1-to-string (t) string) |
| 1242 |
(proclamation princ-to-string (t) string) |
| 1243 |
(proclamation format ((or stream-designator string) |
| 1244 |
format-control &rest t) |
| 1245 |
(or null string)) |
| 1246 |
|
| 1247 |
;; Slot accessor: |
| 1248 |
;; (proclamation print-not-readable-object (condition) t) |
| 1249 |
|
| 1250 |
;; ECL extensions: |
| 1251 |
(proclamation si::pprint-logical-block-helper (t t t string gen-bool string) t) |
| 1252 |
(proclamation si::pprint-pop-helper (t t stream) t) |
| 1253 |
#+formatter (proclamation si::format-princ (stream-designator t gen-bool gen-bool t t integer character) t) |
| 1254 |
#+formatter (proclamation si::format-prin1 (stream-designator t gen-bool gen-bool t t integer character) t) |
| 1255 |
#+formatter (proclamation si::format-print-named-character (character stream-designator) t) |
| 1256 |
#+formatter (proclamation si::format-print-integer (stream-designator t gen-bool gen-bool radix t character character integer) t) |
| 1257 |
#+formatter (proclamation si::format-print-cardinal (stream-designator number) t) |
| 1258 |
#+formatter (proclamation si::format-print-ordinal (stream-designator number) t) |
| 1259 |
#+formatter (proclamation si::format-print-old-roman (stream-designator number) t) |
| 1260 |
#+formatter (proclamation si::format-print-roman (stream-designator number) t) |
| 1261 |
#+formatter (proclamation si::format-fixed (stream-designator t t t integer t character gen-bool) t) |
| 1262 |
#+formatter (proclamation si::format-exponential (stream-designator t t t t integer t character t gen-bool) t) |
| 1263 |
#+formatter (proclamation si::format-general (stream-designator t t t t integer t character t gen-bool) t) |
| 1264 |
#+formatter (proclamation si::format-dollars (stream-designator t integer integer integer character gen-bool gen-bool) t) |
| 1265 |
#+formatter (proclamation si::format-relative-tab (stream-designator integer integer) t) |
| 1266 |
#+formatter (proclamation si::format-absolute-tab (stream-designator integer integer) t) |
| 1267 |
#+formatter (proclamation si::format-justification (stream-designator (or string null) integer integer list gen-bool gen-bool integer integer integer character) t) |
| 1268 |
|
| 1269 |
;;; |
| 1270 |
;;; 23. READER |
| 1271 |
;;; |
| 1272 |
|
| 1273 |
(proclamation copy-readtable (&optional readtable-designator (or readtable null)) |
| 1274 |
readtable :no-side-effects) |
| 1275 |
(proclamation make-dispatch-macro-character |
| 1276 |
(character &optional gen-bool readtable) |
| 1277 |
(member t)) |
| 1278 |
(proclamation read (&optional stream-designator gen-bool t gen-bool) t) |
| 1279 |
(proclamation read-preserving-whitespace |
| 1280 |
(&optional stream-designator gen-bool t gen-bool) t) |
| 1281 |
(proclamation read-delimited-list (character &optional stream-designator gen-bool) |
| 1282 |
list) |
| 1283 |
(proclamation read-from-string (string &optional gen-bool t &key) |
| 1284 |
(values t ext:array-index)) |
| 1285 |
(proclamation readtable-case (readtable) |
| 1286 |
(member :upcase :downcase :preserve :invert) |
| 1287 |
:reader) |
| 1288 |
(proclamation readtablep (t) gen-bool :pure) |
| 1289 |
(proclamation get-dispatch-macro-character |
| 1290 |
(character character &optional readtable-designator) |
| 1291 |
(or function-designator null) |
| 1292 |
:reader) |
| 1293 |
(proclamation set-dispatch-macro-character |
| 1294 |
(character character function-designator |
| 1295 |
&optional readtable-designator) |
| 1296 |
(member t)) |
| 1297 |
(proclamation get-macro-character |
| 1298 |
(character &optional readtable-designator) |
| 1299 |
(values (or function-designator null) gen-bool) |
| 1300 |
:reader) |
| 1301 |
(proclamation set-macro-character |
| 1302 |
(character function-designator |
| 1303 |
&optional gen-bool readtable-designator) |
| 1304 |
(member t)) |
| 1305 |
(proclamation set-syntax-from-char |
| 1306 |
(character character &optional readtable readtable-designator) |
| 1307 |
(member t)) |
| 1308 |
|
| 1309 |
;; ECL extensions: |
| 1310 |
(proclamation si:string-to-object (string &optional t) t) |
| 1311 |
(proclamation si:standard-readtable () readtable) |
| 1312 |
|
| 1313 |
;;; |
| 1314 |
;;; 24. SYSTEM CONSTRUCTION |
| 1315 |
;;; |
| 1316 |
|
| 1317 |
(proclamation compile-file (pathname-designator &key) |
| 1318 |
(values (or pathname null) gen-bool gen-bool)) |
| 1319 |
(proclamation compile-file-pathname (pathname-designator &key) |
| 1320 |
pathname :no-side-effects) |
| 1321 |
(proclamation load ((or stream pathname-designator) &key) gen-bool) |
| 1322 |
(proclamation provide (string-designator) t) |
| 1323 |
(proclamation require (string-designator &optional list) t) |
| 1324 |
|
| 1325 |
;; ECL extensions |
| 1326 |
(proclamation si:clear-compiler-properties (symbol) t) |
| 1327 |
|
| 1328 |
|
| 1329 |
;;; |
| 1330 |
;;; 25. ENVIRONMENT |
| 1331 |
;;; |
| 1332 |
|
| 1333 |
(proclamation decode-universal-time (universal-time &optional time-zone) |
| 1334 |
(values (integer 0 59) |
| 1335 |
(integer 0 59) |
| 1336 |
(integer 0 23) |
| 1337 |
(integer 1 31) |
| 1338 |
(integer 1 12) |
| 1339 |
unsigned-byte |
| 1340 |
(integer 0 6) |
| 1341 |
gen-bool |
| 1342 |
time-zone) |
| 1343 |
:pure) |
| 1344 |
(proclamation encode-universal-time ((integer 0 59) |
| 1345 |
(integer 0 59) |
| 1346 |
(integer 0 23) |
| 1347 |
(integer 1 31) |
| 1348 |
(integer 1 12) |
| 1349 |
unsigned-byte |
| 1350 |
&optional time-zone) |
| 1351 |
universal-time |
| 1352 |
:pure) |
| 1353 |
(proclamation get-universal-time () universal-time :no-side-effects) |
| 1354 |
(proclamation get-decoded-time () |
| 1355 |
(values (integer 0 59) |
| 1356 |
(integer 0 59) |
| 1357 |
(integer 0 23) |
| 1358 |
(integer 1 31) |
| 1359 |
(integer 1 12) |
| 1360 |
unsigned-byte |
| 1361 |
(integer 0 6) |
| 1362 |
gen-bool |
| 1363 |
time-zone) |
| 1364 |
:no-side-effects) |
| 1365 |
(proclamation sleep ((real 0 *)) null) |
| 1366 |
(proclamation apropos (string-designator &optional (or null package-designator)) |
| 1367 |
(values)) |
| 1368 |
(proclamation apropos-list |
| 1369 |
(string-designator &optional (or null package-designator)) |
| 1370 |
list) |
| 1371 |
(proclamation describe (t &optional stream-designator) (values)) |
| 1372 |
(proclamation get-internal-real-time () unsigned-byte :no-side-effects) |
| 1373 |
(proclamation get-internal-run-time () unsigned-byte :no-side-effects) |
| 1374 |
(proclamation disassemble ((or function-designator list)) null) |
| 1375 |
(proclamation room (&optional (member t nil :default)) (values &rest t)) |
| 1376 |
(proclamation ed (&optional t) (values &rest t)) |
| 1377 |
(proclamation inspect (t) (values &rest t)) |
| 1378 |
(proclamation dribble (&optional pathname-designator) (values &rest t)) |
| 1379 |
(proclamation lisp-implementation-type () (or string null) :pure) |
| 1380 |
(proclamation lisp-implementation-version () (or string null) :pure) |
| 1381 |
(proclamation short-site-name () (or string null) :pure) |
| 1382 |
(proclamation long-site-name () (or string null) :pure) |
| 1383 |
(proclamation machine-instance () (or string null) :pure) |
| 1384 |
(proclamation machine-type () (or string null) :pure) |
| 1385 |
(proclamation machine-version () (or string null) :pure) |
| 1386 |
(proclamation software-type () (or string null) :pure) |
| 1387 |
(proclamation software-version () (or string null) :pure) |
| 1388 |
(proclamation user-homedir-pathname (&optional pathname-host) |
| 1389 |
(or pathname null) :no-side-effects) |
| 1390 |
|
| 1391 |
;; ECL extensions |
| 1392 |
|
| 1393 |
(proclamation ext::lisp-implementation-vcs-id () string :pure) |
| 1394 |
(proclamation si::room-report () (values t t t t t t t t)) |
| 1395 |
(proclamation si::reset-gbc-count () t) |
| 1396 |
(proclamation ext:gc (&optional gen-bool) t) |
| 1397 |
(proclamation ext:quit (&optional fixnum) t) |
| 1398 |
(proclamation ext:argc () sequence-index) |
| 1399 |
(proclamation ext:argv (unsigned-byte) base-string) |
| 1400 |
(proclamation ext:getenv (string) (or null string)) |
| 1401 |
(proclamation ext:environ () list) |
| 1402 |
(proclamation ext:system (string) fixnum) |
| 1403 |
(proclamation ext:getpid () si::index) |
| 1404 |
(proclamation ext:make-pipe () (or two-way-stream null)) |
| 1405 |
(proclamation ext:run-program (string list &key) |
| 1406 |
(values (or null two-way-stream) |
| 1407 |
(or null integer) |
| 1408 |
ext:external-process)) |
| 1409 |
(proclamation ext:file-stream-fd (stream) fixnum) |
| 1410 |
(proclamation ext:make-stream-from-fd (fixnum keyword &key) stream) |
| 1411 |
|
| 1412 |
(proclamation si:waitpid (fixnum gen-bool) (values |
| 1413 |
(or null keyword) |
| 1414 |
(or null fixnum) |
| 1415 |
(or null fixnum))) |
| 1416 |
(proclamation si:killpid (fixnum fixnum) fixnum) |
| 1417 |
(proclamation si:run-program-inner (string (or list string) list gen-bool) |
| 1418 |
(values file-stream integer)) |
| 1419 |
(proclamation si:spawn-subprocess (string (or list string) list t t t) |
| 1420 |
(values (or null integer) fixnum fixnum fixnum)) |
| 1421 |
(proclamation ext:terminate-process (t &optional gen-bool) null) |
| 1422 |
|
| 1423 |
(proclamation ext:make-weak-pointer (t) ext:weak-pointer :no-side-effects) |
| 1424 |
(proclamation ext:weak-pointer-value (ext:weak-pointer) t) |
| 1425 |
|
| 1426 |
(proclamation si:unbound () t :pure) |
| 1427 |
(proclamation si:traced-old-definition (t) t :no-side-effects) |
| 1428 |
|
| 1429 |
(proclamation si::expand-set-documentation (t t t) t) |
| 1430 |
(proclamation si::set-documentation (t t t) t) |
| 1431 |
(proclamation si::get-documentation (t t) t) |
| 1432 |
|
| 1433 |
#+clos |
| 1434 |
(proclamation si:allocate-raw-instance (t t fixnum) ext:instance) |
| 1435 |
#+clos |
| 1436 |
(proclamation clos:safe-instance-ref (t fixnum) t) |
| 1437 |
#+clos |
| 1438 |
(proclamation si:instance-ref (t fixnum) t :reader) |
| 1439 |
#+clos |
| 1440 |
(proclamation si::instance-slotds (standard-object) list :reader) |
| 1441 |
#+clos |
| 1442 |
(proclamation si:instance-set (t fixnum t) t) |
| 1443 |
#+clos |
| 1444 |
(proclamation si:instance-class (t) class :reader) |
| 1445 |
#+clos |
| 1446 |
(proclamation si:instance-class-set (t t) t) |
| 1447 |
#+clos |
| 1448 |
(proclamation si:instancep (t) t :pure) |
| 1449 |
#+clos |
| 1450 |
(proclamation si:sl-boundp (t) t :reader) |
| 1451 |
#+clos |
| 1452 |
(proclamation si:sl-makunbound (t fixnum) t) |
| 1453 |
#+clos |
| 1454 |
(proclamation clos:standard-instance-access (standard-object t) t :reader) |
| 1455 |
#+clos |
| 1456 |
(proclamation clos:funcallable-standard-instance-access |
| 1457 |
(clos:funcallable-standard-object t) |
| 1458 |
t :reader) |
| 1459 |
#+clos |
| 1460 |
(proclamation clos::associate-methods-to-gfun (function-name *) |
| 1461 |
generic-function) |
| 1462 |
#+clos |
| 1463 |
(proclamation si::need-to-make-load-form-p (t) gen-bool :pure) |
| 1464 |
|
| 1465 |
#+clos |
| 1466 |
(proclamation clos::load-defclass (t t t t) t) |
| 1467 |
|
| 1468 |
#+(and threads clos) (proclamation mp:compare-and-swap-instance (t fixnum t t) t) |
| 1469 |
#+(and threads clos) (proclamation mp:atomic-incf-instance (t fixnum fixnum) fixnum) |
| 1470 |
|
| 1471 |
;;; |
| 1472 |
;;; A. FFI |
| 1473 |
;;; |
| 1474 |
|
| 1475 |
(proclamation si:pointer (t) unsigned-byte) |
| 1476 |
(proclamation si:foreign-data-p (t) gen-bool :pure) |
| 1477 |
|
| 1478 |
;;; |
| 1479 |
;;; B. Multithreading |
| 1480 |
;;; |
| 1481 |
|
| 1482 |
#+threads (proclamation mp:all-processes () list :no-side-effects) |
| 1483 |
#+threads (proclamation mp:exit-process () t) |
| 1484 |
#+threads (proclamation mp:interrupt-process (mp:process t) gen-bool) |
| 1485 |
#+threads (proclamation mp:make-process (&key) mp:process :no-side-effects) |
| 1486 |
#+threads (proclamation mp:process-active-p (mp:process) gen-bool :reader) |
| 1487 |
#+threads (proclamation mp:process-enable (mp:process) t) |
| 1488 |
#+threads (proclamation mp:process-yield () t) |
| 1489 |
#+threads (proclamation mp:process-join (mp:process) (values &rest t)) |
| 1490 |
#+threads (proclamation mp:process-kill (mp:process) gen-bool) |
| 1491 |
#+threads (proclamation mp:process-suspend (mp:process) gen-bool) |
| 1492 |
#+threads (proclamation mp:process-resume (mp:process) gen-bool) |
| 1493 |
#+threads (proclamation mp:process-name (mp:process) t :reader) |
| 1494 |
#+threads (proclamation mp:process-preset (mp:process t &rest t) mp:process) |
| 1495 |
#+threads (proclamation mp:process-run-function (t t &rest t) t) |
| 1496 |
#+threads (proclamation mp:block-signals () t) |
| 1497 |
#+threads (proclamation mp:restore-signals (t) t) |
| 1498 |
|
| 1499 |
#+threads (proclamation mp:make-lock (&key) mp:lock :no-side-effects) |
| 1500 |
#+threads (proclamation mp:recursive-lock-p (mp:lock) gen-bool :reader) |
| 1501 |
#+threads (proclamation mp:holding-lock-p (mp:lock) gen-bool) |
| 1502 |
#+threads (proclamation mp:lock-name (mp:lock) t :reader) |
| 1503 |
#+threads (proclamation mp:lock-owner (mp:lock) t :reader) |
| 1504 |
#+threads (proclamation mp:lock-count (mp:lock) fixnum :reader) |
| 1505 |
#+threads (proclamation mp:get-lock (mp:lock &optional gen-bool) gen-bool) |
| 1506 |
#+threads (proclamation mp:giveup-lock (mp:lock) (eql t)) |
| 1507 |
|
| 1508 |
#+threads (proclamation mp:make-rwlock (&key) mp:rwlock :no-side-effects) |
| 1509 |
#+threads (proclamation mp:rwlock-name (mp:rwlock) t :reader) |
| 1510 |
#+threads (proclamation mp:get-rwlock-read (mp:rwlock &optional gen-bool) gen-bool) |
| 1511 |
#+threads (proclamation mp:get-rwlock-write (mp:rwlock &optional gen-bool) gen-bool) |
| 1512 |
#+threads (proclamation mp:giveup-rwlock-read (mp:rwlock) (eql t)) |
| 1513 |
#+threads (proclamation mp:giveup-rwlock-write (mp:rwlock) (eql t)) |
| 1514 |
|
| 1515 |
#+threads (proclamation mp:make-condition-variable () mp:condition-variable :no-side-effects) |
| 1516 |
#+threads (proclamation mp:condition-variable-wait (mp:condition-variable mp:lock) (eql t)) |
| 1517 |
;; Currently not supported |
| 1518 |
;; #+threads (proclamation mp:condition-variable-timedwait (mp:condition-variable mp:lock natural) (eql t)) |
| 1519 |
#+threads (proclamation mp:condition-variable-signal (mp:condition-variable) (eql t)) |
| 1520 |
#+threads (proclamation mp:condition-variable-broadcast (mp:condition-variable) (eql t)) |
| 1521 |
|
| 1522 |
#+threads (proclamation mp:make-semaphore (&key) mp:semaphore :no-side-effects) |
| 1523 |
#+threads (proclamation mp:semaphore-name (mp:semaphore) t :reader) |
| 1524 |
#+threads (proclamation mp:semaphore-count (mp:semaphore) fixnum :reader) |
| 1525 |
#+threads (proclamation mp:semaphore-wait-count (mp:semaphore) natural :reader) |
| 1526 |
#+threads (proclamation mp:semaphore-wait (mp:semaphore fixnum real) t) |
| 1527 |
#+threads (proclamation mp:wait-on-semaphore (mp:semaphore &key) t) |
| 1528 |
#+threads (proclamation mp:try-get-semaphore (mp:semaphore &optional fixnum) t) |
| 1529 |
#+threads (proclamation mp:signal-semaphore (mp:semaphore &optional fixnum) t) |
| 1530 |
|
| 1531 |
;;; |
| 1532 |
;;; CDR-5 http://cdr.eurolisp.org/document/5/extra-num-types.html |
| 1533 |
;;; |
| 1534 |
|
| 1535 |
(proclamation ext:negative-fixnum-p (t) gen-bool :pure) |
| 1536 |
(proclamation ext:non-negative-fixnum-p (t) gen-bool :pure) |
| 1537 |
(proclamation ext:non-positive-fixnum-p (t) gen-bool :pure) |
| 1538 |
(proclamation ext:positive-fixnum-p (t) gen-bool :pure) |
| 1539 |
(proclamation ext:array-index-p (t) gen-bool :pure) |
| 1540 |
|
| 1541 |
(proclamation ext:negative-integer-p (t) gen-bool :pure) |
| 1542 |
(proclamation ext:non-negative-integer-p (t) gen-bool :pure) |
| 1543 |
(proclamation ext:non-positive-integer-p (t) gen-bool :pure) |
| 1544 |
(proclamation ext:positive-integer-p (t) gen-bool :pure) |
| 1545 |
|
| 1546 |
(proclamation ext:negative-rational-p (t) gen-bool :pure) |
| 1547 |
(proclamation ext:non-negative-rational-p (t) gen-bool :pure) |
| 1548 |
(proclamation ext:non-positive-rational-p (t) gen-bool :pure) |
| 1549 |
(proclamation ext:positive-rational-p (t) gen-bool :pure) |
| 1550 |
|
| 1551 |
(proclamation ext:negative-ratio-p (t) gen-bool :pure) |
| 1552 |
(proclamation ext:non-negative-ratio-p (t) gen-bool :pure) |
| 1553 |
(proclamation ext:non-positive-ratio-p (t) gen-bool :pure) |
| 1554 |
(proclamation ext:positive-ratio-p (t) gen-bool :pure) |
| 1555 |
|
| 1556 |
(proclamation ext:negative-real-p (t) gen-bool :pure) |
| 1557 |
(proclamation ext:non-negative-real-p (t) gen-bool :pure) |
| 1558 |
(proclamation ext:non-positive-real-p (t) gen-bool :pure) |
| 1559 |
(proclamation ext:positive-real-p (t) gen-bool :pure) |
| 1560 |
|
| 1561 |
(proclamation ext:negative-float-p (t) gen-bool :pure) |
| 1562 |
(proclamation ext:non-negative-float-p (t) gen-bool :pure) |
| 1563 |
(proclamation ext:non-positive-float-p (t) gen-bool :pure) |
| 1564 |
(proclamation ext:positive-float-p (t) gen-bool :pure) |
| 1565 |
|
| 1566 |
(proclamation ext:negative-short-float-p (t) gen-bool :pure) |
| 1567 |
(proclamation ext:non-negative-short-float-p (t) gen-bool :pure) |
| 1568 |
(proclamation ext:non-positive-short-float-p (t) gen-bool :pure) |
| 1569 |
(proclamation ext:positive-short-float-p (t) gen-bool :pure) |
| 1570 |
|
| 1571 |
(proclamation ext:negative-single-float-p (t) gen-bool :pure) |
| 1572 |
(proclamation ext:non-negative-single-float-p (t) gen-bool :pure) |
| 1573 |
(proclamation ext:non-positive-single-float-p (t) gen-bool :pure) |
| 1574 |
(proclamation ext:positive-single-float-p (t) gen-bool :pure) |
| 1575 |
|
| 1576 |
(proclamation ext:negative-double-float-p (t) gen-bool :pure) |
| 1577 |
(proclamation ext:non-negative-double-float-p (t) gen-bool :pure) |
| 1578 |
(proclamation ext:non-positive-double-float-p (t) gen-bool :pure) |
| 1579 |
(proclamation ext:positive-double-float-p (t) gen-bool :pure) |
| 1580 |
|
| 1581 |
(proclamation ext:negative-long-float-p (t) gen-bool :pure) |
| 1582 |
(proclamation ext:non-negative-long-float-p (t) gen-bool :pure) |
| 1583 |
(proclamation ext:non-positive-long-float-p (t) gen-bool :pure) |
| 1584 |
(proclamation ext:positive-long-float-p (t) gen-bool :pure) |
| 1585 |
|
| 1586 |
))) ; eval-when |
| 1587 |
|
| 1588 |
(loop for i in '#.(mapcar #'rest +proclamations+) |
| 1589 |
do (apply #'parse-function-proclamation i)) |
| 1590 |
|