Tony Mechelynck wrote:
> Hello,
>
> AFAICT, has('unnamedplus') is documented only under 'clipboard'. Not
> under |feature-list| which is supposed to list all possible arguments
> for which has() might test true. I'm attaching a patch to fix this
> "documentation bug".
>
> There is also no +unnamedplus feature and no mention of 'unnamedplus'
> under |+feature-list| or in the output of |:version| even when
> has('unnamedplus') tests true (as in gvim for GTK2). This might be
> intentional though, so I didn't "correct" it.
>
> Inspection of the code seems to indicate that (in current Vim versions)
> has('unnamedplus') is equivalent with (has('clipboard') && has('x11'))
> (see src/eval.c lines 12194-12196); of course the test is still useful
> to discriminate against versions older than the introduction of the feature.
>
> However, in any Vim with +clipboard the user may :set
> clipboard=unnamedplus with no error, even on platforms which have
> +clipboard but -x11 such as Windows. Yet "really" unsupported values
> such as :set clipboard=foobar give error E474 "Invalid argument".
> Shouldn't there be # ifdef FEAT_X11 ... # endif around lines 7324-7329
> of src/option.c for consistency with the has() result, so that trying to
> set the value where it isn't supported should give that same error? This
> would also be more consistent with older versions, in the sense that
> trying to :set clipboard=unnamedplus would give an error wherever
> has('unnamedplus') == 0, be it because !has('x11') or because of using
> an "old" Vim version where the feature wasn't yet defined.
Thanks, I'll add this to the todo list (which now has a scary long list
of patches...).
--
I'm not familiar with this proof, but I'm aware of a significant
following of toddlers who believe that peanut butter is the solution
to all of life's problems... -- Tim Hammerquist
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
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