We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 12f9bf0 commit f0fa9e6Copy full SHA for f0fa9e6
lib/elixir/lib/string.ex
@@ -1048,6 +1048,10 @@ defmodule String do
1048
If the start of the range is not a valid offset for the given
1049
string or if the range is in reverse order, returns `""`.
1050
1051
+ If the start or end of the range are negative, the whole string
1052
+ is traversed first in order to convert the negative indexes into
1053
+ positive ones.
1054
+
1055
Remember this function works with unicode codepoints and consider
1056
the slices to represent codepoints offsets. If you want to split
1057
on raw bytes, check `Kernel.binary_part/3` instead.
0 commit comments