[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: Confusion Over Keyword Arguments

Berger, Daniel

3/2/2006 6:12:00 PM

Yukihiro Matsumoto wrote:
> Hi,
>
> In message "Re: Confusion Over Keyword Arguments"
> on Fri, 3 Mar 2006 02:30:34 +0900, Daniel Berger <Daniel.Berger@qwest.com> writes:
>
> |> foo(1, foo:3) # (a=1, b={:foo=>3}) or (a=1,b=0,c=[{:foo=>3}])?
> |
> |Error. There's no 'foo' parameter. Passing a literal hash would require {}.
>
> I'm not sure what you meant by "literal hash". Do you mean foo:3 is
> not legal since you don't have an argument with a name "foo"?
>
> Have you changed your mind since the blog entry at
> http://djberg96.livejournal.com/5... For you have written
>
>
>>foo(1, 2, foo:4, bar:5) # a=1, b=2, c=[{'foo'=>4, 'bar'=>5}]
>>foo(1, 2, 8, baz:5) # a=1, b=2, c=[8, {'baz'=>5}]
>
>
> in it. foo:4 etc. seems like non-literal hash.

Oops - I didn't notice you had declared it "*c" instead of "c". My blog entry
is the expected behavior.

> |> args = [1, {:b=>2, foo=>5}]
> |> foo(*args) # (a=1,b={:b=>2, foo=>5}) or (a=1,b=2,c=[{:foo=>5}])?
> |
> |a = 1, b = {:b=>2, foo=>5}, since you've passed a literal hash.
>
> This means that you cannot accept
>
> (a) a keyword argument that is possibly accepted by the superclass's
> method, without knowing their names

I'm not sure I follow. How would you know the keyword arguments without
knowing their names? Or are we getting into keyword discovery here?

> (b) arbitrary keywords that can be passed to other methods

What do you mean by 'arbitrary keywords'?

> Right? If so, (a) means you need to have exact argument information
> about a superclass method, which may not be available for mix-in
> modules;

I'm afraid I'm not following.

(b) means there's no way to convert keyword arguments to a
> hash.

Are you talking internals, or by the user?

Well, anyway, I think this has all been gone over before. I probably should
have just kept my mouth shut.

Dan


12 Answers

Barb May

9/24/2011 2:39:00 AM

0

RichA wrote:
> On Sep 23, 2:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv> wrote:
>> Rich wrote:
>>> CNN:
>>
>>> http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
>>> clintons-stuff/?npt=NP1
>>
>> Yeah, he stole it and kept it hidden "in an Arkansas library" among
>> "nearly 2,000 boxes of archived documents."
>>
>> --
>> Barb
>
> Sure. No one ever heard of hiding stolen goods. If that thing showed
> up at auction, it would easily fetch $500k.

This was not "stolen goods." It was packed up by a moving company when
Clinton left the governor's office and those thousands of boxes were
delivered to an Arkansas library. The boxes were in the custody of the
library and were being cataloged by a library worker. In the 30+ years
since Clinton left the Arkansas governor's office those boxes have never
been under Clinton's control.

The way you wingnuts try to twist this stuff around is really pathetic.
Give it up, Rich.


--
Barb


Not Sure

9/24/2011 2:47:00 AM

0

On Sep 23, 7:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv> wrote:
> RichA wrote:
> > On Sep 23, 2:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv> wrote:
> >> Rich wrote:
> >>> CNN:
>
> >>>http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
> >>> clintons-stuff/?npt=NP1
>
> >> Yeah, he stole it and kept it hidden "in an Arkansas library" among
> >> "nearly 2,000 boxes of archived documents."
>
> >> --
> >> Barb
>
> > Sure.  No one ever heard of hiding stolen goods.  If that thing showed
> > up at auction, it would easily fetch $500k.
>
> This was not "stolen goods." It was packed up by a moving company when
> Clinton left the governor's office and those thousands of boxes were
> delivered to an Arkansas library. The boxes were in the custody of the
> library and were being cataloged by a library worker. In the 30+ years
> since Clinton left the Arkansas governor's office those boxes have never
> been under Clinton's control.
>
> The way you wingnuts try to twist this stuff around is really pathetic.
> Give it up, Rich.

Hey, clouddipshit, it's been awhile since you signed on under this
handle. I'm guessing your Messiah's pathetic performance over the last
few months means even your sycophantic and fat ass can't protect him
anymore, huh? :)

>
> --
> Barb

Ubiquitous

9/24/2011 3:00:00 AM

0

barbmay@nonofyourbusinessx.tv wrote:

>The way you wingnuts try to twist this stuff around is really pathetic.

Projection noted. Get back to us when you have a real argument to make.

--
"Admittedly, conservatives give as good as they get. The difference
between us and [leftists] is that we can argue as well as inveigh.
They can only hurl invectives." -- Don Feder


JustDoIt

9/24/2011 5:48:00 AM

0

"Barb May" <barbmay@nonofyourbusinessx.tv> wrote in news:4e7d4314$1@news.x-
privat.org:

> RichA wrote:
>> On Sep 23, 2:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv> wrote:
>>> Rich wrote:
>>>> CNN:
>>>
>>>> http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
>>>> clintons-stuff/?npt=NP1
>>>
>>> Yeah, he stole it and kept it hidden "in an Arkansas library" among
>>> "nearly 2,000 boxes of archived documents."
>>>
>>> --
>>> Barb
>>
>> Sure. No one ever heard of hiding stolen goods. If that thing showed
>> up at auction, it would easily fetch $500k.
>
> This was not "stolen goods." It was packed up by a moving company when
> Clinton left the governor's office and those thousands of boxes were
> delivered to an Arkansas library. The boxes were in the custody of the
> library and were being cataloged by a library worker. In the 30+ years
> since Clinton left the Arkansas governor's office those boxes have never
> been under Clinton's control.
>
> The way you wingnuts try to twist this stuff around is really pathetic.
> Give it up, Rich.
>
>

But he's entitled to it...

Newsweek Poll: Clinton More Elitist
Posted on April 26, 2008 by Dillon

The Newsweek poll released today has some interesting fodder for
discussion.

?which of the candidates, if any, looks down on people like you??

Clinton: 32%; Obama: 25%; McCain: 26%

trotsky

9/24/2011 1:39:00 PM

0

On 9/23/11 9:39 PM, Barb May wrote:
> RichA wrote:
>> On Sep 23, 2:39 pm, "Barb May"<barb...@nonofyourbusinessx.tv> wrote:
>>> Rich wrote:
>>>> CNN:
>>>
>>>> http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
>>>> clintons-stuff/?npt=NP1
>>>
>>> Yeah, he stole it and kept it hidden "in an Arkansas library" among
>>> "nearly 2,000 boxes of archived documents."
>>>
>>> --
>>> Barb
>>
>> Sure. No one ever heard of hiding stolen goods. If that thing showed
>> up at auction, it would easily fetch $500k.
>
> This was not "stolen goods." It was packed up by a moving company when
> Clinton left the governor's office and those thousands of boxes were
> delivered to an Arkansas library. The boxes were in the custody of the
> library and were being cataloged by a library worker. In the 30+ years
> since Clinton left the Arkansas governor's office those boxes have never
> been under Clinton's control.
>
> The way you wingnuts try to twist this stuff around is really pathetic.
> Give it up, Rich.


Give it up? As soon as he learns how to tie a noose it's all over.

Barb May

9/24/2011 7:04:00 PM

0

Rich wrote:
> "Barb May" <barbmay@nonofyourbusinessx.tv> wrote in
> news:4e7d4314$1@news.x- privat.org:
>
>> RichA wrote:
>>> On Sep 23, 2:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv>
>>> wrote:
>>>> Rich wrote:
>>>>> CNN:
>>>>
>>>>> http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
>>>>> clintons-stuff/?npt=NP1
>>>>
>>>> Yeah, he stole it and kept it hidden "in an Arkansas library" among
>>>> "nearly 2,000 boxes of archived documents."
>>>>
>>>> --
>>>> Barb
>>>
>>> Sure. No one ever heard of hiding stolen goods. If that thing
>>> showed up at auction, it would easily fetch $500k.
>>
>> This was not "stolen goods." It was packed up by a moving company
>> when Clinton left the governor's office and those thousands of boxes
>> were delivered to an Arkansas library. The boxes were in the custody
>> of the library and were being cataloged by a library worker. In the
>> 30+ years since Clinton left the Arkansas governor's office those
>> boxes have never been under Clinton's control.
>>
>> The way you wingnuts try to twist this stuff around is really
>> pathetic. Give it up, Rich.
>>
>>
>
> But he's entitled to it...
>
> Newsweek Poll: Clinton More Elitist
> Posted on April 26, 2008 by Dillon

April 2008?
Ancient history.

>
> The Newsweek poll released today has some interesting fodder for
> discussion.
>
> "which of the candidates, if any, looks down on people like you?"
>
> Clinton: 32%; Obama: 25%; McCain: 26%

The Clinton referenced in the poll is Hillary, not Bill because Bill was
not a candidate in 2008. Didn't that occur to you, Rich?

The same poll also said this:

"which of the candidates, if any, would be most likely to favor the
interests of the rich and powerful in their policies as president?"

Clinton: 29%; Obama: 8%; McCain: 46%

The poll shows quite clearly who would most likely favor the rich and
that's far more important in terms of what policies they are likely to
pursue than which candidate might think they are better than average
folk.

--
Barb


ralph

9/24/2011 8:44:00 PM

0

Think I'm falling for Barb in a big way.

Barb May

9/25/2011 6:14:00 PM

0

ralph wrote:
> Think I'm falling for Barb in a big way.

:-)
--
Barb


Liberal $500 million tax dollar disaster

9/26/2011 8:02:00 PM

0

On Sep 24, 3:03 pm, "Barb May" <barb...@nonofyourbusinessx.tv> wrote:
> Rich wrote:
> > "Barb May" <barb...@nonofyourbusinessx.tv> wrote in
> >news:4e7d4314$1@news.x-privat.org:
>
> >> RichA wrote:
> >>> On Sep 23, 2:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv>
> >>> wrote:
> >>>> Rich wrote:
> >>>>> CNN:
>
> >>>>>http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
> >>>>> clintons-stuff/?npt=NP1
>
> >>>> Yeah, he stole it and kept it hidden "in an Arkansas library" among
> >>>> "nearly 2,000 boxes of archived documents."
>
> >>>> --
> >>>> Barb
>
> >>> Sure.  No one ever heard of hiding stolen goods.  If that thing
> >>> showed up at auction, it would easily fetch $500k.
>
> >> This was not "stolen goods." It was packed up by a moving company
> >> when Clinton left the governor's office and those thousands of boxes
> >> were delivered to an Arkansas library. The boxes were in the custody
> >> of the library and were being cataloged by a library worker. In the
> >> 30+ years since Clinton left the Arkansas governor's office those
> >> boxes have never been under Clinton's control.
>
> >> The way you wingnuts try to twist this stuff around is really
> >> pathetic. Give it up, Rich.
>
> > But he's entitled to it...
>
> > Newsweek Poll: Clinton More Elitist
> > Posted on April 26, 2008 by Dillon
>
> April 2008?
> Ancient history.
>
>
>
> > The Newsweek poll released today has some interesting fodder for
> > discussion.
>
> >    "which of the candidates, if any, looks down on people like you?"
>
> >    Clinton: 32%; Obama: 25%; McCain: 26%
>
> The Clinton referenced in the poll is Hillary, not Bill because Bill was
> not a candidate in 2008. Didn't that occur to you, Rich?
>
> The same poll also said this:
>
> "which of the candidates, if any, would be most likely to favor the
> interests of the rich and powerful in their policies as president?"
>
> Clinton: 29%; Obama: 8%; McCain: 46%
>

Well, they go that wrong, didn't they? They ALL favour the rich
because they are all rich themselves!

Nancy2

9/26/2011 8:11:00 PM

0

On Sep 23, 1:39 pm, "Barb May" <barb...@nonofyourbusinessx.tv> wrote:
> Rich wrote:
> > CNN:
>
> >http://lightyears.blogs.cnn.com/2011/09/22/moon-rock-found-a...
> > clintons-stuff/?npt=NP1
>
> Yeah, he stole it and kept it hidden "in an Arkansas library" among
> "nearly 2,000 boxes of archived documents."
>
> --
> Barb

Good grief, talk about grasping at straws. Likely some staffer packed
it up with other Clinton presidential documents and didn't think any
more about it. I'm sure Bill didn't know it was in that stuff.

N.