Bram Moolenaar wrote:
> Tony Mechelynck wrote:
>
>> :mksession (in 7.1.077) or gvim -S (in 7.1.079) doesn't work properly
>> in UTF-8 locale with Unicode codepoints (> U+007F) in 'listchars'
>>
>> gvim 7.1.077 in UTF-8 locale
>> [...]
>> :set lcs=tab:\|_,eol:=B6,nbsp:~
>> [...]
>> :mks!
>> :qa
>> (patch to 7.1.079, make, make install)
>> gvim -S
>>
>> Error detected while processing /root/Session.vim:
>> line 79:
>> E474: Invalid argument: listchars=tab:|_,eol:Â=B6,nbsp:~
>>
>> The offending Session.vim is attached
>
> You already mentioned that 'encoding' somehow got set to "latin1". Note
> that when 'encoding' changes that many option values may become invalid.
> Vim doesn't go over all options and convert them from the old to the new
> encoding.
>
> In this specific case: I suspect 'encoding' was "utf-8", you have set
> 'listchars' to include a multi-byte character, and then 'encoding' was
> set to "latin1". 'listchars' will then have an invalid value.
>
Yes, that seems to be what happened, except I don't recall ever changing
'encoding' to latin1. I honestly thought it was still UTF-8, which is my
system locale and also what my vimrc sets if it finds out that
if &enc =~? '^u'
is FALSE at startup. But I have been using :mks!, :qa, recompile Vim, gvim -S
so the spurious ":set enc=latin1" would be in the earlier session -- ":verbose
set enc? lcs?" only says they were set by Session.vim which in this case isn't
helpful.
Best regards,
Tony.
--
"The lawgiver, of all beings, most owes the law allegiance. He of all
men should behave as though the law compelled him. But it is the
universal weakness of mankind that what we are given to administer we
presently imagine we own."
-- H.G. Wells
--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---