I think you  can reproduce the case like this

open a new vim :

source the code below :
---------------------------code 1-----------------------------
call bufnr( "PV_LISTBUF_8680477943" ,1 )
call setbufvar( 2 , "&modifiable" , 0 )
call setbufvar( 2 , "&swapfile" , 0 )
call setbufvar( 2 , "&buftype" , "nofile" )
call setbufvar( 2 , "&readonly" , 1 )
call setbufvar( 2 , "&bufhidden" , "hide" )
call setbufvar( 2 , "&buflisted" , 0 )
-----------------------------------------------------------------

and now , source these code :
-----------------------code 2-----------------------------------
echo getbufvar( 2 , "&modifiable")
echo getbufvar( 2 , "&swapfile" )
echo getbufvar( 2 , "&buftype" )
echo getbufvar( 2 , "&readonly" )
echo getbufvar( 2 , "&bufhidden" )
echo getbufvar( 2 , "&buflisted" )
------------------------------------------------------------------

My result is below ( the same as i set by code1 ) :
-------------------------result 1---------------------------------
0
0
nofile
1
hide
0
---------------------------------------------------------------------

The problem occur when i just want to show the buffer
do this by :buffer 2
then , source the code2 again
At this time , my result is like this :
-------------------------result 2 ----------------------------------
1
0
0
0
-----------------------------------------------------------------------

All my setting to the buffer 2 seems to be discarded.

Is there anything wrong with my operation ?

PS:
   version info : vi...@winxp

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

Raspunde prin e-mail lui