fixes #22867; fixes cstring modification example on Nim Manual (#22871)

fixes #22867
This commit is contained in:
ringabout
2023-10-26 16:06:44 +08:00
committed by GitHub
parent 7c3917d1dd
commit cef5e57eb5

View File

@@ -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
```