diff options
author | Thomas Bushnell <tb@debian.org> | 2006-10-23 23:31:59 -0700 |
---|---|---|
committer | Bryan Newbold <bnewbold@robocracy.org> | 2017-02-20 00:05:35 -0800 |
commit | 906cc4f0899080f1b832af98b7ccbcc257b8a64e (patch) | |
tree | 14e3ec231debdca4da9c1a3ccc0536033c1c8a4b /byte.c | |
parent | 3d573fa54db0fdcae8b2a20356faa46c8e335206 (diff) | |
parent | 50eb784bfcf15ee3c6b0b53d747db92673395040 (diff) | |
download | scm-906cc4f0899080f1b832af98b7ccbcc257b8a64e.tar.gz scm-906cc4f0899080f1b832af98b7ccbcc257b8a64e.zip |
Import Debian changes 5e3-1debian/5e3-1
scm (5e3-1) unstable; urgency=low
* New upstream release.
* debian/control (Architecture): Add ia64 to list of supported archs. Now
everything but s390 is listed. (Closes: #335980)
(Build-Depends): Require at least version 3a4 of slib.
* Change to continue.h from version 5e1-2 repeated here.
* Change to xgen.scm from version 5e2-4 repeated here.
* Change to scm.1 from version 5e2-4 repeated here.
Diffstat (limited to 'byte.c')
-rw-r--r-- | byte.c | 23 |
1 files changed, 13 insertions, 10 deletions
@@ -149,8 +149,8 @@ SCM scm_read_byte(port) return MAKINUM(c); } -static char s_sub_rd[] = "substring-read!"; -SCM scm_substring_read(sstr, start, args) +static char s_sub_rd[] = "subbytes-read!"; +SCM scm_subbytes_read(sstr, start, args) SCM sstr, start, args; { SCM end, port; @@ -196,8 +196,8 @@ SCM scm_substring_read(sstr, start, args) } } -static char s_sub_wr[] = "substring-write"; -SCM scm_substring_write(sstr, start, args) +static char s_sub_wr[] = "subbytes-write"; +SCM scm_subbytes_write(sstr, start, args) SCM sstr, start, args; { SCM end, port; @@ -246,8 +246,8 @@ static iproc subr2os[] = { {0, 0}}; static iproc lsubr2s[] = { - {s_sub_rd, scm_substring_read}, - {s_sub_wr, scm_substring_write}, + {s_sub_rd, scm_subbytes_read}, + {s_sub_wr, scm_subbytes_write}, {0, 0}}; @@ -264,14 +264,15 @@ void init_byte() scm_ldstr("\n\ (define bytes-length string-length)\n\ (define bytes-copy string-copy)\n\ +(define subbytes substring)\n\ (define (bytes-reverse bytes)\n\ (bytes-reverse! (bytes-copy bytes)))\n\ (define (read-bytes n . port)\n\ (let* ((len (abs n))\n\ (byts (make-bytes len))\n\ (cnt (if (positive? n)\n\ - (apply substring-read! byts 0 n port)\n\ - (apply substring-read! byts (- n) 0 port))))\n\ + (apply subbytes-read! byts 0 n port)\n\ + (apply subbytes-read! byts (- n) 0 port))))\n\ (if (= cnt len)\n\ byts\n\ (if (positive? n)\n\ @@ -279,7 +280,9 @@ void init_byte() (substring byts (- len cnt) len)))))\n\ (define (write-bytes bytes n . port)\n\ (if (positive? n)\n\ - (apply substring-write bytes 0 n port)\n\ - (apply substring-write bytes (- n) 0 port)))\n\ + (apply subbytes-write bytes 0 n port)\n\ + (apply subbytes-write bytes (- n) 0 port)))\n\ +(define substring-read! subbytes-read!)\n\ +(define substring-write subbytes-write)\n\ "); } |