diff options
author | Ludovic Courtès <ludo@gnu.org> | 2009-10-15 23:29:50 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2009-10-15 23:29:50 +0200 |
commit | cd48c32cf4c1f627e9f9eeb8f7e077e0a414eab8 (patch) | |
tree | f233eb69d4789e6dd931485d2740e7254639ae3f /libguile/arrays.c | |
parent | 29553c54b597880d329013c6b4b435e2949a9872 (diff) | |
download | guile-cd48c32cf4c1f627e9f9eeb8f7e077e0a414eab8.tar.gz |
Fix compilation of literal bitvectors.
* libguile/arrays.c (scm_from_contiguous_typed_array): Fix BYTE_LEN
sanity check for bitvectors.
* test-suite/tests/unif.test ("syntax")["bitvector is self-evaluating"]:
New test.
* module/ice-9/deprecated.scm (#\y): Fix deprecation comment: `#*' is
not a read syntax.
Diffstat (limited to 'libguile/arrays.c')
-rw-r--r-- | libguile/arrays.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libguile/arrays.c b/libguile/arrays.c index b9386ea10..1fd6d9245 100644 --- a/libguile/arrays.c +++ b/libguile/arrays.c @@ -243,7 +243,8 @@ scm_from_contiguous_typed_array (SCM type, SCM bounds, const void *bytes, } else { - if (rlen * (sz / 8) + rlen * (sz % 8) / 8 != byte_len) + /* byte_len ?= ceil (rlen * sz / 8) */ + if (byte_len != (rlen * sz + 7) / 8) SCM_MISC_ERROR ("byte length and dimensions do not match", SCM_EOL); } |