# \#safe-string

**URL:** https://discuss.ocaml.org/tag/safe-string/176.md

[Latest](https://discuss.ocaml.org/latest.md) · [Categories](https://discuss.ocaml.org/categories.md) · [Tags](https://discuss.ocaml.org/tags.md)

---

## [Warning when using \`a.\[b\] \<- c\` operator with bytes](https://discuss.ocaml.org/t/warning-when-using-a-b-c-operator-with-bytes/1484)

<div class="topic-metadata">

**Author:** [@bcc32](https://discuss.ocaml.org/u/bcc32)\
**Replies:** 8\
**Last updated:** [March 26, 2018, 12:19am UTC](https://discuss.ocaml.org/t/warning-when-using-a-b-c-operator-with-bytes/1484 "2018-03-26T00:19:56Z")

</div>

Prior to -safe-string, the a.\[b\] \<- c operator was used to modify characters in a string: let s = String.make 3 '\\000' in s.\[0\] \<- 'f'; s.\[1\] \<- 'o'; s.\[2\] \<- 'o'; With safe-string, only bytes may be modified, not stri…
