On 29 March 2010 01:21, Andrew Garrett <[email protected]> wrote:
> * I don't like that the trivial case is Message::key() – you can't
> beat the brevity of a global function, and I'd like to see something
> short and to the point.

That's why I asked whether there needs to be a wrapper (global
function) which calls Message::key() and what should it be.

> * I don't like the idea of passing parameters through a call chain –
> it's just not how things are really done in PHP, and it leads to all
> sorts of bizarre behaviour (like the bug mentioned above). It's not
> really in conformance with standard MediaWiki syntax. I don't see that
> it confers any advantages over named parameters.

If you can't do everything in one call (or chain of calls), you need
to create temporary variables. I bet people are not going to like that
either.
Call chains are very flexible and readable (in my opinion at least).
It could be possible to add parameters already in Message::key(). It
actually already allows that, but as an array. I'd actually prefer if
it too took varargs instead, since I dislike PHP's array syntax.

 -Niklas

-- 
Niklas Laxström

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to