Commit the local DARCS CFFI repo, as well as update to today.
[CommonLispStat.git] / external / cffi.darcs / _darcs / pristine / src / package.lisp
blob3b48d169316d719286babce2c6fa565ad1ccd992
1 ;;;; -*- Mode: lisp; indent-tabs-mode: nil -*-
2 ;;;
3 ;;; package.lisp --- Package definition for CFFI.
4 ;;;
5 ;;; Copyright (C) 2005-2006, James Bielman <jamesjb@jamesjb.com>
6 ;;;
7 ;;; Permission is hereby granted, free of charge, to any person
8 ;;; obtaining a copy of this software and associated documentation
9 ;;; files (the "Software"), to deal in the Software without
10 ;;; restriction, including without limitation the rights to use, copy,
11 ;;; modify, merge, publish, distribute, sublicense, and/or sell copies
12 ;;; of the Software, and to permit persons to whom the Software is
13 ;;; furnished to do so, subject to the following conditions:
14 ;;;
15 ;;; The above copyright notice and this permission notice shall be
16 ;;; included in all copies or substantial portions of the Software.
17 ;;;
18 ;;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
19 ;;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
20 ;;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
21 ;;; NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
22 ;;; HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
23 ;;; WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24 ;;; OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25 ;;; DEALINGS IN THE SOFTWARE.
26 ;;;
28 (in-package #:cl-user)
30 (defpackage #:cffi
31 (:use #:common-lisp #:cffi-sys #:cffi-utils)
32 (:import-from #:cffi-features #:cffi-feature-p)
33 (:export
34 ;; Types.
35 #:foreign-pointer
37 ;; Primitive pointer operations.
38 #:foreign-free
39 #:foreign-alloc
40 #:mem-aref
41 #:mem-ref
42 #:pointerp
43 #:pointer-eq
44 #:null-pointer
45 #:null-pointer-p
46 #:inc-pointer
47 #:incf-pointer
48 #:with-foreign-pointer
49 #:make-pointer
50 #:pointer-address
52 ;; Shareable vectors.
53 #:make-shareable-byte-vector
54 #:with-pointer-to-vector-data
56 ;; Foreign string operations.
57 #:foreign-string-alloc
58 #:foreign-string-free
59 #:foreign-string-to-lisp
60 #:lisp-string-to-foreign
61 #:with-foreign-string
62 #:with-foreign-strings
63 #:with-foreign-pointer-as-string
65 ;; Foreign function operations.
66 #:defcfun
67 #:foreign-funcall
68 #:foreign-funcall-pointer
70 ;; Foreign library operations.
71 #:*foreign-library-directories*
72 #:*darwin-framework-directories*
73 #:define-foreign-library
74 #:load-foreign-library
75 #:load-foreign-library-error
76 #:use-foreign-library
77 #:close-foreign-library
79 ;; Callbacks.
80 #:callback
81 #:get-callback
82 #:defcallback
84 ;; Foreign type operations.
85 #:defcstruct
86 #:defcunion
87 #:defctype
88 #:defcenum
89 #:defbitfield
90 #:define-foreign-type
91 #:define-parse-method
92 #:foreign-enum-keyword
93 #:foreign-enum-keyword-list
94 #:foreign-enum-value
95 #:foreign-bitfield-symbol-list
96 #:foreign-bitfield-symbols
97 #:foreign-bitfield-value
98 #:foreign-slot-pointer
99 #:foreign-slot-value
100 #:foreign-slot-offset
101 #:foreign-slot-names
102 #:foreign-type-alignment
103 #:foreign-type-size
104 #:with-foreign-object
105 #:with-foreign-objects
106 #:with-foreign-slots
107 #:convert-to-foreign
108 #:convert-from-foreign
109 #:free-converted-object
111 ;; Extensible foreign type operations.
112 #:translate-to-foreign
113 #:translate-from-foreign
114 #:free-translated-object
115 #:expand-to-foreign-dyn
116 #:expand-to-foreign
117 #:expand-from-foreign
119 ;; Foreign globals.
120 #:defcvar
121 #:get-var-pointer
122 #:foreign-symbol-pointer