Duncan Booth, 08.11.2012 14:58:
> Ulrich Eckhardt wrote:
>> If possible, I'm looking for a solution that works for Pythons 2 and 3,
>> since I'm not fully through the conversion yet and have clients that
>> might use the older snake for some time before shedding their skin.
>>
>> Suggestions?
>
Ulrich Eckhardt wrote:
> If possible, I'm looking for a solution that works for Pythons 2 and 3,
> since I'm not fully through the conversion yet and have clients that
> might use the older snake for some time before shedding their skin.
>
> Suggestions?
Why bother checking types at all?
def
On Thu, 08 Nov 2012 13:05:22 +0100, Ulrich Eckhardt wrote:
> Firstly, I have code that allows either a file or a string representing
> its content as parameter. If the parameter is a file, the content is
> read from the file. In Python 2, I used "isinstance(p, file)" to
> determine whether the par
Ulrich Eckhardt wrote:
> Hi!
>
> I have two problems that are related and that I'd like to solve together.
>
> Firstly, I have code that allows either a file or a string representing
> its content as parameter. If the parameter is a file, the content is
> read from the file. In Python 2, I used
On Thu, Nov 8, 2012 at 11:05 PM, Ulrich Eckhardt
wrote:
> Firstly, I have code that allows either a file or a string representing its
> content as parameter. If the parameter is a file, the content is read from
> the file. In Python 2, I used "isinstance(p, file)" to determine whether the
> parame
On 2012-11-08 12:05, Ulrich Eckhardt wrote:
Hi!
I have two problems that are related and that I'd like to solve together.
Firstly, I have code that allows either a file or a string representing
its content as parameter. If the parameter is a file, the content is
read from the file. In Python 2,
Hi!
I have two problems that are related and that I'd like to solve together.
Firstly, I have code that allows either a file or a string representing
its content as parameter. If the parameter is a file, the content is
read from the file. In Python 2, I used "isinstance(p, file)" to
determine