fix bug in prefab syntax marshaling

Closes PR 12352
This commit is contained in:
Matthew Flatt 2011-11-12 06:08:42 -07:00
parent edec6fafd1
commit a0378a2b02
2 changed files with 10 additions and 1 deletions

View File

@ -627,6 +627,15 @@
(test 10 'ten (invoke compare)))
;; ----------------------------------------
;; Check zo marshaling of prefab in a list:
(let ([s #'(quote-syntax (#s(foo bar)))])
(define-values (i o) (make-pipe))
(parameterize ([current-namespace (make-base-namespace)]
[read-accept-compiled #t])
(write (compile s) o)
(test (syntax->datum (eval (read i))) values '(#s(foo bar)))))
;; ----------------------------------------

View File

@ -6338,7 +6338,7 @@ static Scheme_Object *extract_for_common_wrap(Scheme_Object *a, int get_mark, in
else
return SCHEME_CDR(v);
}
} else if (!SCHEME_BOXP(v) && !SCHEME_VECTORP(v)) {
} else if (!SCHEME_BOXP(v) && !SCHEME_VECTORP(v) && !prefab_p(v)) {
/* It's atomic. */
if (get_mark)
return SCHEME_CDR(a);