From a513aedbe19491d72bcad3bddeef7b3cd44afb4a Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Fri, 3 Nov 2017 20:23:26 -0700 Subject: [PATCH] Fix incorrect use of && where & should have been used. --- src/microcode/debug.c | 4 ++-- src/microcode/string.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/microcode/debug.c b/src/microcode/debug.c index 26fe18fce..70ca800fa 100644 --- a/src/microcode/debug.c +++ b/src/microcode/debug.c @@ -260,8 +260,8 @@ print_ustring (outf_channel stream, SCHEME_OBJECT string) long_enough = (length < 100 ? length : 90); next = (STRING_LOC (string, 0)); - cp_size = ((OBJECT_TYPE (MEMORY_REF (string, BYTEVECTOR_LENGTH_INDEX))) - && 0x03); + cp_size + = ((OBJECT_TYPE (MEMORY_REF (string, BYTEVECTOR_LENGTH_INDEX))) & 0x03); if (cp_size == 0) { print_simple (stream, string); diff --git a/src/microcode/string.c b/src/microcode/string.c index e687adc5a..0f249f4a5 100644 --- a/src/microcode/string.c +++ b/src/microcode/string.c @@ -40,7 +40,7 @@ string_p (SCHEME_OBJECT object) // one byte per code point. This must be kept in sync // with "runtime/ustring.scm". && (((OBJECT_TYPE (MEMORY_REF (object, BYTEVECTOR_LENGTH_INDEX))) - && 0x03) + & 0x03) == 0x01))); } -- 2.25.1