mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-31 18:32:11 +00:00
fixes #22867
This commit is contained in:
@@ -1495,7 +1495,8 @@ it can be modified:
|
||||
|
||||
```nim
|
||||
var x = "123456"
|
||||
var s: cstring = x
|
||||
prepareMutation(x) # call `prepareMutation` before modifying the strings
|
||||
var s: cstring = cstring(x)
|
||||
s[0] = 'u' # This is ok
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user