ved icon indicating copy to clipboard operation
ved copied to clipboard

use `string.len_utf8()` instead of `utf8_str_len(string)`

Open StunxFS opened this issue 2 years ago • 2 comments

Fix notice:

./ved.v:475:15: notice: function `utf8_str_len` will be deprecated after 2022-05-28, and will become an error after 2022-11-24; use `string.len_utf8()` instead
  473 |         // Handle utf8 codepoints
  474 |         // old_len := s.len
  475 |         if s.len != utf8_str_len(s) {
      |                     ~~~~~~~~~~~~~~~
  476 |             u := s.runes()
  477 |             if max > 0 && max < u.len {

StunxFS avatar May 19 '22 23:05 StunxFS

/home/runner/work/ved/ved/ved/view.v is not vfmt'ed
/home/runner/work/ved/ved/ved/ved.v is not vfmt'ed

medvednikov avatar May 20 '22 15:05 medvednikov

@medvednikov vfmt'ed

StunxFS avatar Jul 07 '22 19:07 StunxFS

Already fixed on master.

medvednikov avatar Aug 31 '22 15:08 medvednikov