I'd like to cache some information about file, into b:variables, and be able to check in my function, whether buffer changed in any way between 2 calls to the function. Is there any "change counter" that I can store and compare later to detect the buffer change (any change like any insertion, deletion, undo, redo, file was re-read from disk) ?
I though about using &modified but it does not work. If file was modified and saved, then &modified is off and I don't detect anything. Yakov