~ubuntu-branches/ubuntu/intrepid/ecl/intrepid

« back to all changes in this revision

Viewing changes to src/cmp/sysfun.lsp

  • Committer: Bazaar Package Importer
  • Author(s): Albin Tonnerre
  • Date: 2008-06-20 18:00:19 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20080620180019-7fbz1ln5444vtkkr
Tags: 0.9j-20080306-2ubuntu1
* Enabled unicode support. (Closes: LP #123530)
* Modify Maintainer value to match the DebianMaintainerField specification.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
;;;;  -*- Mode: Lisp; Syntax: Common-Lisp; Package: C -*-
 
2
;;;;
1
3
;;; CMPSYSFUN   Database for system functions.
2
4
;;;
3
5
;;; Copyright (c) 2003, Juan Jose Garcia Ripoll
66
68
  nil)
67
69
 
68
70
(defmacro def-inline (name safety arg-types return-rep-type expansion
 
71
                      &key (one-liner t)
69
72
                      &aux arg-rep-types)
70
73
  (setf safety
71
74
        (case safety
82
85
                           :return-type (rep-type->lisp-type return-rep-type)
83
86
                           :arg-types arg-types
84
87
;                          :side-effects (not (get-sysprop name 'no-side-effects))
 
88
                           :one-liner one-liner
85
89
                           :expansion expansion)))
86
90
    (put-sysprop name safety (cons inline-info (get-sysprop name safety))))
87
91
  nil)
258
262
(def-inline both-case-p :always (character) :bool "ecl_both_case_p(#0)")
259
263
 
260
264
(proclaim-function digit-char-p (character *) t :no-side-effects t)
261
 
(def-inline digit-char-p :always (character) :bool
262
 
 "@0; ((#0) <= '9' && (#0) >= '0')")
263
265
 
264
266
(proclaim-function alphanumericp (character) t :predicate t :no-side-effects t)
265
267
(def-inline alphanumericp :always (character) :bool "isalnum(#0)")
379
381
;; file unixfsys.d
380
382
 
381
383
(proclaim-function truename (t) t)
382
 
(proclaim-function rename-file (t t) t)
 
384
(proclaim-function rename-file (t t *) t)
383
385
(proclaim-function si:specialp (t) t :predicate t)
384
386
(proclaim-function delete-file (t) t)
385
387
(proclaim-function probe-file (t) t)
846
848
(proclaim-function logbitp (t t) t :predicate t :no-side-effects t)
847
849
(def-inline logbitp :always ((integer -29 29) fixnum) :bool "(#1 >> #0) & 1")
848
850
 
849
 
(proclaim-function ash (t t) t)
 
851
(proclaim-function ash (integer integer) t)
850
852
(proclaim-function logcount (t) t)
851
853
(proclaim-function integer-length (t) fixnum)
852
854
(proclaim-function si:bit-array-op (*) t)
1311
1313
 
1312
1314
(proclaim-function c::ldb1 (fixnum fixnum fixnum) fixnum :no-side-effects t)
1313
1315
(def-inline c::ldb1 :always (fixnum fixnum fixnum) :fixnum
1314
 
 "((((~(-1 << (#0))) << (#1)) & (#2)) >> (#1))")
 
1316
 "((((~((cl_fixnum)-1 << (#0))) << (#1)) & (cl_fixnum)(#2)) >> (#1))")
1315
1317
(def-inline c::ldb1 :always (fixnum fixnum fixnum) t
1316
 
 "MAKE_FIXNUM((((~(-1 << (#0))) << (#1)) & (#2)) >> (#1))")
 
1318
 "MAKE_FIXNUM((((~((cl_fixnum)-1 << (#0))) << (#1)) & (cl_fixnum)(#2)) >> (#1))")
1317
1319
 
1318
1320
;; Functions only available with CLOS
1319
1321
 
1387
1389
    nsubst-if nsubst-if-not
1388
1390
    ;; mislib.lsp
1389
1391
    logical-pathname-translations load-logical-pathname-translations decode-universal-time
1390
 
    encode-universal-time get-decoded-time get-universal-time
 
1392
    encode-universal-time get-decoded-time
1391
1393
    ensure-directories-exist si::simple-program-error si::signal-simple-error
1392
1394
    ;; module.lsp
1393
1395
    provide require
1437
1439
    si::pprint-logical-block-helper si::pprint-pop-helper
1438
1440
    si::make-seq-iterator si::seq-iterator-ref si::seq-iterator-set si::seq-iterator-next
1439
1441
    si::assert-slot-type si::define-structure
1440
 
    .
1441
 
    #-clos
1442
 
    nil
 
1442
    #+formatter
 
1443
    ,@'(
 
1444
    format-princ format-prin1 format-print-named-character
 
1445
    format-print-integer
 
1446
    format-print-cardinal format-print-ordinal format-print-old-roman
 
1447
    format-print-roman format-fixed format-exponential
 
1448
    format-general format-dollars
 
1449
    format-relative-tab format-absolute-tab
 
1450
    format-justification
 
1451
        )
1443
1452
    #+clos
1444
 
    (;; defclass.lsp
 
1453
    ,@'(;; defclass.lsp
1445
1454
     clos::ensure-class
1446
1455
     ;; boot.lsp
1447
1456
     clos::slot-boundp