Re: Stupid Language Designer Tricks

2012-05-15 Thread Peter da Silva
On 2012-05-14, at 10:58, H.Merijn Brand wrote: Reminds me of an April-fools article introducing COME FROM to the language to ease debugging. In the end of that article they also described COME FROM ON Hilarious http://en.wikipedia.org/wiki/COMEFROM

Re: Stupid Language Designer Tricks

2012-05-15 Thread Peter da Silva
On 2012-05-14, at 07:51, David Cantrell wrote: For extra excitement, perl has this nifty feature where you can index from the end of an array using negative numbers: @array = ('ant', 'bat', 'camel', 'dolphin'); print $array[-1]; # dolphin print $array[-2]; # camel That really _is_ a nifty

Re: Stupid Language Designer Tricks

2012-05-15 Thread David Cantrell
On Tue, May 15, 2012 at 05:15:56AM -0500, Peter da Silva wrote: On 2012-05-14, at 07:51, David Cantrell wrote: For extra excitement, perl has this nifty feature where you can index from the end of an array using negative numbers: @array = ('ant', 'bat', 'camel', 'dolphin'); print

Re: Stupid Language Designer Tricks

2012-05-15 Thread Darrell Fuhriman
Well, while we're ranting about stupid language design desisions... I would like to dish out a special platter of hate for Puppet. Well, not a programming language per se. But Puppet is special in that it's intended to be a *descriptive* language. So you describe how your servers are to be

Re: Stupid Language Designer Tricks

2012-05-15 Thread Tony Finch
Darrell Fuhriman darr...@garnix.org wrote: I'm personally of the opinion that they should abandon the custom DSL in favor of a pure ruby implementation, but I seem to be on the losing end of that argument. This is one of the weirder design decisions of Puppet, given how fashionable embedded

Re: Stupid Language Designer Tricks

2012-05-15 Thread demerphq
On 15 May 2012 12:22, Peter da Silva pe...@taronga.com wrote: On 2012-05-14, at 10:58, H.Merijn Brand wrote: Reminds me of an April-fools article introducing COME FROM to the language to ease debugging. In the end of that article they also described COME FROM ON Hilarious

Re: Stupid Language Designer Tricks

2012-05-15 Thread Michael G Schwern
On 2012.5.14 2:44 AM, Numien wrote: But, that is another good point: * We'll add file access and persistent storage later Still don't count that as a design mistake in Javascript, but a design feature. It was designed as a secure language and that means very, very restricted I/O and storage.

Re: Stupid Language Designer Tricks

2012-05-15 Thread Michael G Schwern
On 2012.5.14 5:08 AM, Aristotle Pagaltzis wrote: * Peter Corlett ab...@cabal.org.uk [2012-05-14 12:20]: On Mon, May 14, 2012 at 11:06:59AM +0200, demerphq wrote: I kinda wish perl had an interface like my $iter= iterator(%hash); while (my ($key,$value)= $iter-each) { } Which I think would

Re: Stupid Language Designer Tricks

2012-05-15 Thread Michael G Schwern
On 2012.5.14 2:06 AM, demerphq wrote: On 14 May 2012 02:17, Michael G Schwern schw...@pobox.com wrote: So much hate for tying the iterator to the data and not the op. Indeed. I see this bite people regularly at $work (non Perl programmers converting seem to get bitten by each() at least once

Re: Stupid Language Designer Tricks

2012-05-15 Thread Michael G Schwern
On 2012.5.14 2:47 AM, H.Merijn Brand wrote: * undef/NULL handling * Oracle converts to NULL on varchar2 fields * MySQL considers the date -00-00 both NULL and NOT NULL at the same time I would boil that down to trinary logic. A good idea that NOBODY gets it right. If you do