On Thu, Jan 26, 2012 at 6:54 PM, Ojan Vafai <[email protected]> wrote: > > That said, I sympathize that the overhead of creating an object or needing > to do a string compare just for a boolean is kind of sucky. >
I'd expect implementations to mostly optimize away string comparisons with string interning, though. On Thu, Jan 26, 2012 at 7:01 PM, Tab Atkins Jr. <[email protected]> wrote: > That's not necessary. There are situations when optional arguments > make sense. They should be avoided, though, when you expect that > *future* optional arguments will have nothing to do with the current > one, as otherwise you'll have to specify the "optional" argument every > time with some null value. > > Charles gives examples of a few arguments we may want to provide in > the future, all of which have nothing to do with whether the url is > single-use or reusable. > This is all fine. It's only the argument that booleans are so much more opaque than other argument types (numbers, at least) that I find unconvincing. -- Glenn Maynard
