On May 1, 11:10 pm, "Gabriel Genellina" <[EMAIL PROTECTED]>
wrote:
> En Wed, 02 May 2007 02:31:43 -0300, <[EMAIL PROTECTED]> escribió:
>
> > A better question is why this doesn't work.
>
> >>>> pathparts = ["/foo", "bar"]
> >>>> os.path.join(pathparts)
> > ['/foo', 'bar']
>
> > This should return a string in my opinion.
>
> I think it's a bug, but because it should raise TypeError instead.
> The right usage is os.path.join(*pathparts)
>
> --
> Gabriel Genellina

Wow.  What exactly is that * operator doing?  Is it only used in
passing args to functions?  Does it just expand the list into
individual string arguments for exactly this situation?  Or does it
have other uses?

~Sean

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to