str = "(θ,)"
str[3]
results in
ERROR: StringIndexError: invalid index [3], valid nearby indices [2]=>'θ', [4]=>','
Stacktrace:
[1] string_index_err(s::String, i::Int64)
@ Base ./strings/string.jl:12
[2] getindex_continued(s::String, i::Int64, u::UInt32)
@ Base ./strings/string.jl:235
[3] getindex(s::String, i::Int64)
@ Base ./strings/string.jl:228
[4] top-level scope
@ REPL[11]:1
I’m guessing maybe not a bug but unicode related. Still it feels unexpected to me. Should this be expected behaviour?