mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
bare: fix str[idx]
This commit is contained in:
parent
a545ccb740
commit
dc50ed69cf
@ -7,3 +7,7 @@ pub fn panic(s string) {
|
|||||||
//write(1, s.str, s.len)
|
//write(1, s.str, s.len)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn panic_debug(s string) {
|
||||||
|
//write(1, s.str, s.len)
|
||||||
|
}
|
||||||
|
|
||||||
|
@ -211,7 +211,7 @@ fn (p mut Parser) index_get(typ string, fn_ph int, cfg IndexConfig) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if cfg.is_str && !p.builtin_mod {
|
else if cfg.is_str && !p.builtin_mod && !p.pref.is_bare {
|
||||||
if cfg.is_slice {
|
if cfg.is_slice {
|
||||||
p.gen('string_substr2($index_expr)')
|
p.gen('string_substr2($index_expr)')
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user