;; strings need dedicated zcopy
;; so need to override default
(bind-func zcopy:[String*,String*,mzone*,mzone*]*
(lambda (x fromz toz)
(if (llvm_ptr_in_zone fromz (cast x i8*))
(begin (push_zone toz)
(let ((obj (zalloc)))
(begin
(tset! obj 0 (tref x 0)))
(if (llvm_ptr_in_zone fromz (cast (tref x 1) i8*))
(let ((newptr:i8* (zalloc (+ 1 (tref x 0)))))
(strcpy newptr (cast (tref x 1) i8*)) ; (+ (tref x 0) 1))
(tset! obj 1 newptr))
(tset! obj 1 (tref x 1)))
(pop_zone)
obj))
x)))