Boost logo

Boost :

From: David B. Held (dheld_at_[hidden])
Date: 2004-11-16 17:43:48


Thorsten Ottosen wrote:
> [...]
> Currently it is really a pain in the *** to have an object with many default
> arguments. Your library makes that managable; but I argue
> functions with many arguments should be refactored since their level of
> abstraction is getting too low; allowing many default arguments
> juat makes the situation worse.

You keep saying that, but I wonder if you actually have to write any
real-world code, or if perhaps you are simply an academic? I have
many instances of functions with numerous arguments for which I offer
no apology and would resist any attempt by you or anyone else to
refactor into functions with fewer arguments. There is such a thing as
too much abstraction. Next you will go around insisting that everyone
uses your int wrapper which automatically detects overflow. Sometimes,
having a function with many arguments is simply the best solution to a
problem, just like sometimes, goto is the best solution. Just because
it isn't always the best solution doesn't mean that it is never the
best solution. To assert otherwise would require me to throw a logic
error. ;)

Dave


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk