[RDY] clipboard: support separate +/* clipboards, linewise copy/paste and add test

This change allows clipboard provider to distinguish between `+` and `*` registers, by passing an extra parameter to clipboard_get/set. 

Existing behaviour can be preserved by just igoring the extra parameter like [this](https://gist.github.com/bfredl/19c13ba8014bb761528c). An example provider for X11 that distinguishes between "primary selection" and clipboard (like in vim +x11) is [here](https://gist.github.com/bfredl/888e2b7c2b378d6953ee)

An open question is what to do when `unnamedclip` is set; right now it uses the name `+` (because it was easiest to implement and consistent with existing code). An alternative would be to pass the name `"` to the provider when the unnamed register is used (so it could choose between `+`/`*` itself, or implemnt a third option). In this case, and if I understand the code correctly, `adjust_clipboard_register` could be be completely removed? @tarruda

While breaking the API, something to consider is to let the provider get/set the regtype (character or linewise selection) by passing another parameter. I suppose this could be done by just doing `vim.command("call getregtype(...)")` from the provider, but IMHO it would be cleaner if this was actually part of the api. I will try to implement this later.
:+1: i've must have copypasted dict_add_list too quickly...
Den 31 dec 2014 01:09 skrev "oni-link" <notifications@github.com>:

> In src/nvim/eval.c
> <https://github.com/neovim/neovim/pull/1182#discussion-diff-22370989>:
>
> > @@ -5119,6 +5119,20 @@ void list_append_tv(list_T *l, typval_T *tv)
> >  }
> >
> >  /*
> > + * Add a list to a list.
> > + */
> > +void list_append_list(list_T *list, list_T *itemlist)
> > +{
> > +  listitem_T  *li = listitem_alloc();
> > +
> > +  li->li_tv.v_type = VAR_LIST;
> > +  li->li_tv.v_lock = 0;
> > +  li->li_tv.vval.v_list = itemlist;
> > +  list_append(list, li);
> > +  ++list->lv_refcount;
>
> itemlist is referenced in list, so we should use ++itemlist->lv_refcount
> here.
> The refcount of list should probably be increased somewhere else.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/neovim/neovim/pull/1182/files#r22370989>.
>