Changeset 5296
- Timestamp:
- Oct 5, 2006, 5:09:49 AM (18 years ago)
- File:
-
- 1 edited
-
trunk/ccl/lib/macros.lisp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ccl/lib/macros.lisp
r5230 r5296 1576 1576 (defmacro with-cstrs (speclist &body body) 1577 1577 (with-specs-aux 'with-cstr speclist body)) 1578 1579 (defmacro with-encoded-cstr (encoding-name (sym string &optional start end) 1580 &rest body &environment env) 1581 (let* ((encoding (get-character-encoding encoding-name)) 1582 (str (gensym))) 1583 (multiple-value-bind (body decls) (parse-body body env nil) 1584 `(let* ((,str ,string)) 1585 (%stack-block ((,sym (cstring-encoded-length-in-bytes ,encoding ,str ,start ,end) :clear t)) 1586 ,@decls 1587 (encode-string-to-memory ,encoding ,sym 0 ,str ,start ,end) 1588 ,@body))))) 1589 1590 (defmacro with-encoded-cstrs (encoding-name bindings &body body) 1591 (with-specs-aux 'with-encoded-cstr (mapcar #'(lambda (b) 1592 `(,encoding-name ,b)) 1593 bindings) body)) 1578 1594 1579 1595
Note:
See TracChangeset
for help on using the changeset viewer.
