Skip to content
Prev 50095 / 63424 Next

Proposing a change in the base::sink interface for type argument

Thanks Don/Kasper for the detailed explanation. Understood the idea behind
match.arg. Meanwhile, it might look handy, the part I am finding tricky is
that it makes the signature of the function misleading. That is, client
would have no idea that a particular arg is accessed through match.arg. So,
unless (A) this is well-documented or (B) one go read the implementation,
he wouldn't know the actual type of the arg is atomic not a vector. To be
fair, in the case of sink, documentation is clear that type is a character.
So, I am dropping my request. But, I probably won't use match.arg myself
given the illusion it causes in the interface of a function.

Thanks,
Hamid

On Wed, Mar 18, 2015 at 4:48 PM, Kasper Daniel Hansen <
kasperdanielhansen at gmail.com> wrote: