in reply to Re^7: Why? (each...)
in thread Why? (each...)

My point is that the idea that parens create a list is flawed. How is that relevant?

Replies are listed 'Best First'.
Re^9: Why? (each...)
by Argel (Prior) on May 13, 2011 at 18:37 UTC
    "Indicate" is not the same as "create" and I never said "create"!! And we were talking about in certain situations/context yet your examples are all over the map. We're clearly not on the same page.

    Elda Taluta; Sarks Sark; Ark Arks

      It's even more far fetch that they indicate a list, and I pointed this out too. For every example you gave where it does, I gave examples where parens didn't indicate a list (high false positive ratio), and examples where lists existed without parens (high false negative ratio).

      Parens are a low precision indicator of lists (not likely to be correct), and parens are a low recall indicator of lists (not likely to find instances of lists).

        Look at the OP's question. Seems clear he is confused about when to use {}, [], and () in the context of variable creation/assignment. So with that in mind, given "my %hash = ( x => 'a', y => 'b', z => 'c')" the parens are used to indicate where the list of key/value pairs begins and ends. Ergo, they indicate a list. Yes, the comma operator provides the list context, but it's not useful for distinguishing when to use {}, [], or (). I was thinking more in terms of a "list of key/value pairs".

        Elda Taluta; Sarks Sark; Ark Arks