Changeset 6041 for trunk/j/src/org/armedbear/lisp/ldb.lisp
- Timestamp:
- 02/28/04 18:40:42 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/j/src/org/armedbear/lisp/ldb.lisp
r3723 r6041 1 1 ;;; ldb.lisp 2 2 ;;; 3 ;;; Copyright (C) 2003 Peter Graves4 ;;; $Id: ldb.lisp,v 1. 2 2003-09-12 14:16:44piso Exp $3 ;;; Copyright (C) 2003-2004 Peter Graves 4 ;;; $Id: ldb.lisp,v 1.3 2004-02-28 18:40:08 piso Exp $ 5 5 ;;; 6 6 ;;; This program is free software; you can redistribute it and/or … … 18 18 ;;; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 19 19 20 (in-package "SYSTEM") 21 20 22 (defun byte (size position) 21 23 (cons size position)) … … 26 28 (defun byte-position (bytespec) 27 29 (cdr bytespec)) 30 31 ;; For the LDB compiler macro. 32 (defun %ldb (size position integer) 33 (logand (ash integer (- position)) 34 (1- (ash 1 size)))) 28 35 29 36 (defun ldb (bytespec integer)
Note: See TracChangeset
for help on using the changeset viewer.