summary refs log tree commit diff stats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/pure/streams.nim2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/pure/streams.nim b/lib/pure/streams.nim
index 7ad81685f..84451f989 100644
--- a/lib/pure/streams.nim
+++ b/lib/pure/streams.nim
@@ -1274,6 +1274,8 @@ else: # after 1.3 or JS not defined
 
     new(result)
     result.data = s
+    when defined(gcOrc) or defined(gcArc):
+      prepareMutation(result.data) # Allows us to mutate using `addr` logic like `copyMem`, otherwise it errors.
     result.pos = 0
     result.closeImpl = ssClose
     result.atEndImpl = ssAtEnd