On 31/07/11 02:16, Mariano Guerra wrote:
hi, I'm Mariano, long time vim user, lately I've been interested in
understanding vim internals, my main doubt right now are the following:

* which data structure is used to handle a document?

try running cscope over the Vim source, then look for "buffer"

* how are undos handled?

That depends on the u flag in 'cpoptions' (see :help cpo-u) and on the 'undofile' option. Not sure about the details.

* how are marks handled?

They are remembered as properties of the buffer and stored in the viminfo file (if 'viminfo' is nonempty and its "apostrophe" sub-option, which must always be there if the option is nonempty, has a nonzero value). Uppercase marks are visible across files, lowercase marks are for the current file only.

* is there any resource other than source code to read about this topics?

I don't think so; but you can use cscope and/or Exuberant Ctags to help you analyze the source.

About ctags: If on a Unix-like OS, use "make tags" in the top-level Makefile. For Windows etc., the same may work but I'm less sure. Thereafter you can use the :tag command (q.v.), or Ctrl-] just as in helpfiles

About cscope: see http://vim.wikia.com/wiki/Cscope


if not a brief description and a pointer to the correct part of the
source code would be enough to start with.

thanks!


Best regards,
Tony.
--
A New York City ordinance prohibits the shooting of rabbits from the
rear of a Third Avenue street car -- if the car is in motion.

--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Raspunde prin e-mail lui