[Gambas-user] Concatenate collection
T Lee Davidson
t.lee.davidson at gmail.com
Wed Sep 6 16:39:31 CEST 2023
On 9/6/23 08:55, Jussi Lahtinen wrote:
> It would be something like that:
>
> For Each v In b
> a[b.Key] = v
> Next
>
> Three lines of code should not be a big deal.
>
> But yes, it could be put into the interpreter as an Insert() method.
>
>
> What about duplicate keys?
>
> Jussi
Good question. There would probably need to be a Mode parameter that tells the method how to handle them. Like, perhaps,
'overwrite' the receiver's key/value with the Inserted key/value, do not overwrite, or quarantine duplicate Inserted keys into a
separate collection.
--
Lee
More information about the User
mailing list