VIM: How to position on a given offset?

A program of mine gives me error positions based on the file offset and not the line containing the error. How can I locate the address in vim?

Well, there are two commands can be used to position on a given char offset.

:go 2048

(with colon), or


(without colon)

They both requires +byte_offset feature, i.e., has(“byte_offset”) must return nonzero value. For more details you can refer to “:help go”.

Leave a comment

Your email address will not be published. Required fields are marked *