On 11/11/08 06:36, StarWing wrote:
> BUT, this is not the responsibility of c.vim! now i had to add this
> line to c.vim, but it should be done by Vim when i changed the
> filetype! because every indent script should define a variable named
> "b:undo_indent", and Vim will "exec b:undo_indent" when it use a new
> indent (see indent.vim in vim folder, it's very clear.). first bug is
> caused because "vim.vim" didn't have a b:undo_indent, and second bug
> is caused Vim didn't exec b:undo_indent when we edit a second file in
> the first buffer!!

If you set 'indentexpr' manually while editing some file which, maybe, 
has no satisfying indent script and maybe even no defined filetype (so 
that it won't have a b:undo_indent unless you are thoughtful enough to 
manually provide one), and then you use ":edit foobar.c" to edit a C 
file in the same window, the indent/c.vim should set indentation to what 
it needs. Now it is true that the default for 'indentexpr' is empty, but 
if for some reason it happens not to be empty the 'cindent' set by the C 
indent plugin will not be taken into account.

Best regards,
Tony.
-- 
        In war we're tough and able.
        Quite indefatigable
        Between our quests
        We sequin vests
        And impersonate Clark Gable
        It's a busy life in Camelot.
        I have to push the pram a lot.
          "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to