Forgot the changes in the original announcement:
* Fixed embarrassing misinterpretation of
sax.handler.feature_namespace_prefixes
Now Namespace prefixes work fine with or without PyXML installed
* Add saxtools.namespace_mixin utility class
* Clean up bindery.document_base name attributes
*
On 30 Dec 2004 08:58:36 -0800, Sridhar R
[EMAIL PROTECTED] wrote:
What makes such companies to choose Java over dynamic, productive
languages like Python? Are there any viable, technical reasons for
that?
Decisions are made by men in suits who read very expensive
business magazines, read
Sridhar R [EMAIL PROTECTED] writes:
What makes such companies to choose Java over dynamic, productive
languages like Python? Are there any viable, technical reasons for that?
I think you have to be more careful when you program in Python. Java
is statically typed and can do all kinds of
Hi David,
Thanks for the bit of code on finding shares! I'd been using something a
bit different (win32com.client stuff) but your code looks better.
I've found that win32file.FindFilesIterator (suggested to me by another
person on this mailing list) allows the gui to remain responsive. Using
John Roth wrote:
I appreciate some of the motivation, but merely avoiding giving
something a name doesn't seem like a laudible goal.
Actually, it is a laudable goal. It's always easier to understand
something when it's right in front of your face than if it's
off somewhere else.
Naming the
Minimal setup.py example, run with:
% python setup.py py2app
from distutils.core import setup
import py2app
setup(
app = ['main.py'],
)
That is a sample code of wiki.
I have a file 'main.py' and several sub-folders.
After I execute 'pythonw setup.py py2exe', I see 2 folders, 'dist'
On Thu, 30 Dec 2004 12:06:31 -0800, Scott David Daniels
[EMAIL PROTECTED] wrote:
Here's one way: # (Make __iter__ an iterator)
Py class R1(object):
def __init__(self, data):
self.data = data
self.i = len(data)
def __iter__(self):
while
On Fri, 2004-12-31 at 11:17, Jeremy Bowers wrote:
I would point out a couple of other ideas, though you may be aware of
them: Compressing all the files seperately, if they are small, may greatly
reduce the final compression since similarities between the files can not
be exploited.
True;
On Thu, 30 Dec 2004 12:59:57 -0500, Steve Holden [EMAIL PROTECTED]
wrote:
We either need time for folks to accept dynamic, scripting
languages, or a lot of modern language programmers need to gang up
against managers and stuff. :)
[...]
Right, what have the managers ever done for us?
I must
On 30.12.2004, at 01:24, It's me wrote:
I would not think that a generic deepcopy would work for all cases.
An
object can be as simple as a number, for instance, but can also be as
complex as the universe. I can't imagine anybody would know how to
copy a
complex object otherthen the object
Thomas Bartkus [EMAIL PROTECTED] writes:
[...]
What makes such companies to choose Java over dynamic, productive
languages like Python? Are there any viable, technical reasons
for that?
Are there viable, technical reasons? That would be doubtful.
But
There is a reason very
On 31-dec-04, at 11:12, Austin wrote:
Minimal setup.py example, run with:
% python setup.py py2app
from distutils.core import setup
import py2app
setup(
app = ['main.py'],
)
That is a sample code of wiki.
I have a file 'main.py' and several sub-folders.
After I execute 'pythonw setup.py
On Fri, 31 Dec 2004 02:13:27 +0100, Bulba! wrote:
On 30 Dec 2004 08:58:36 -0800, Sridhar R
[EMAIL PROTECTED] wrote:
[snip]
What makes such companies to choose Java over dynamic, productive
languages like Python? Are there any viable, technical reasons for
that?
It's the $$$ of the big
On Fri, 31 Dec 2004 12:05:47 +0100, Peter Dembinski wrote:
Thomas Bartkus [EMAIL PROTECTED] writes:
[...]
What makes such companies to choose Java over dynamic, productive
languages like Python? Are there any viable, technical reasons
for that?
Are there viable, technical reasons?
harold fellermann [EMAIL PROTECTED] wrote:
...
I always think that a well designed object should have a copyme method.
:=)
That would be __copy__ or __deepcopy__, but the __getstate__ /
__setstate__ approach is often preferable.
take a look at the __setstate__ and __getstate__
Christopher Koppler [EMAIL PROTECTED] writes:
The moral is, of course, that either the Python community's alpha
geeks need to get access to controlling interest in a *major*
company (or to become successful enough with their own companies to
register on the current *major* companies radar as
Thanks for your suggestion, but it has several problems which the added
class solves:
* This is a very long code just to write you must implement this
method. Having a standard way to say that is better.
* You can instantiate the base class, which doesn't make sense.
* You must use testing to
On Fri, 31 Dec 2004 03:49:44 -0800, Paul Rubin wrote:
Christopher Koppler [EMAIL PROTECTED] writes:
The moral is, of course, that either the Python community's alpha
geeks need to get access to controlling interest in a *major*
company (or to become successful enough with their own companies
Christopher Koppler [EMAIL PROTECTED] writes:
IMO (and - indubitably limited - experience) in the many cases where it
*would* be an excellent choice, it *is* most often a matter of politics,
to have a project use, say C# or Java instead of Python (or Lisp for that
matter) as the main
Hi,
I'm using
Python 2.3.4 (#53, May 25 2004, 21:17:02) [MSC v.1200 32 bit (Intel)]
on win32
I've noticed a strange (= not deterministic) behaviour of ftplib.py:
sometimes (not always) it fails (after a variable number of minutes
from 15 to 130) downloading a 150 MB BINARY file
(a big gzipped
On Fri, 31 Dec 2004 04:03:53 -0800, Paul Rubin wrote:
Christopher Koppler [EMAIL PROTECTED] writes:
IMO (and - indubitably limited - experience) in the many cases where it
*would* be an excellent choice, it *is* most often a matter of politics,
to have a project use, say C# or Java instead of
On Wed, 15 Dec 2004 17:37:08 -0500, rumours say that Peter Hansen
[EMAIL PROTECTED] might have written:
Martijn Faassen wrote:
Peter Hansen wrote:
Well, in any case, thanks for setting the record straight, Martjin.
That of course also happens to me once every while. I can take care of
Craig Ringer wrote:
On Fri, 2004-12-31 at 11:17, Jeremy Bowers wrote:
I would point out a couple of other ideas, though you may be aware of
them: Compressing all the files seperately, if they are small, may greatly
reduce the final compression since similarities between the files can not
be
On 31 Dec 2004 03:49:44 -0800, Paul Rubin
http://[EMAIL PROTECTED] wrote:
It's not just a matter of attitude or politics. Python is an
excellent choice for many projects. For some other projects, it's
clearly unsuitable. For yet other projects, it's a plausible choice
but there are sound
Paul Rubin http://[EMAIL PROTECTED] writes:
[...]
I'm involved in a development project for something that's security
critical and has to be reliable. The implementation language hasn't
been chosen yet. Python and Java are both possibilities. I'm fine
with the idea of using Python for
On Fri, 31 Dec 2004 13:19:44 +0100, Reinhold Birkenfeld
[EMAIL PROTECTED] wrote:
True; however, it's my understanding that compressing individual files
also means that in the case of damage to the archive it is possible to
recover the files after the damaged file. This cannot be guaranteed
On Thu, 30 Dec 2004 22:17:10 -0500, Jeremy Bowers [EMAIL PROTECTED]
wrote:
I would point out a couple of other ideas, though you may be aware of
them: Compressing all the files seperately, if they are small, may greatly
reduce the final compression since similarities between the files can not
be
matplotlib is a 2D graphics package that produces plots from python
scripts, the python shell, or embeds them in your favorite python GUI
-- wx, gtk, tk, fltk currently supported with qt in the works. Unlike
many python plotting alternatives is written in python, so it is
easy to extend.
Bulba! [EMAIL PROTECTED] writes:
OK, so what projects and why would you consider Python:
1. clearly unsuitable
An OS kernel, a high-performance signal processing application like a
video encoder, or maybe a compact embedded application for an 8-bit
microcontroller. Note that you could do
Peter Dembinski [EMAIL PROTECTED] writes:
If it has to be both reliable and secure, I suggest you used more
redundant language such as Ada 95.
That's something to think about and it's come up in discussions, but
probably complicates stuff since it's not currently available on the
target
So, those are my thoughts on how lambdas are really used. If others
out there have real-life code that uses lambdas in interesting ways,
feel free to share them here!
I use them in conjunction with metaclasses and properties:
def _s_item(self, item):
saw::active
Bulba! [EMAIL PROTECTED] writes:
The only thing I'm missing in this picture is knowledge if my script
could be further optimised (not that I actually need better
performance, I'm just curious what possible solutions could be).
Any takers among the experienced guys?
There's another
That's not bad going considering you've only run out of alcohol at 6 in
the morning and *then* ask python questions.
Anyway - you could write a charcter-by-character parser function that
would do that in a few minutes...
My 'listquote' module has one - but it splits on commas not whitespace.
On Fri, 31 Dec 2004 05:54:05 -0800, Paul Rubin wrote:
Bulba! [EMAIL PROTECTED] writes:
OK, so what projects and why would you consider Python:
1. clearly unsuitable
An OS kernel, a high-performance signal processing application like a
video encoder, or maybe a compact embedded
Well,
I have not read the previous version, but
I would like to see an example how to redirect console messages
from scripts to Tk windows in UTF-8/16 for debugging purposes.
(I hate those ordinal not in range(128) messages)
This involves setting font (Arial MS Unicode), scrollbar and
Continue
Reread Russel Blau post he is spot on with his comments:
Russel Blau wrote:
I don't get that from the passage quoted, at all, although it is
somewhat
opaque. It says that your __iter__() method must *return an object*
with a
next() method; your __iter__() method below doesn't return such an
Christopher Koppler [EMAIL PROTECTED] wrote:
...
What makes such companies to choose Java over dynamic, productive
languages like Python? Are there any viable, technical reasons
for that?
...
There is a reason very important to major companies. When you leave
that company,
Freddie wrote:
Happy new year! Since I have run out of alcohol, I'll ask a question that I
haven't really worked out an answer for yet. Is there an elegant way to turn
something like:
moo cow farmer john -zug
into:
['moo', 'cow', 'farmer john'], ['zug']
I'm trying to parse a
Christopher Koppler [EMAIL PROTECTED] wrote:
The moral is, of course, that either the Python community's alpha geeks
need to get access to controlling interest in a *major* company (or to
become successful enough with their own companies to register on the
current *major* companies radar as
On 2004-12-29, Scott David Daniels [EMAIL PROTECTED] wrote:
Antoon Pardon wrote:
Op 2004-12-23, Scott David Daniels schreef [EMAIL PROTECTED]:
This is half the problem. In the period where an element is in the
wrong hash bucket, a new entry for the same value can be created in
the proper hash
[EMAIL PROTECTED] (Alex Martelli) writes:
Well, Google's market capitalization must be around 50 billion dollars
or more, in the range of the top-100 companies, I believe, and they've
never kept their Python use a secret.
They use Python for a lot of internal tools but their high-volume
Paul Rubin writes:
I don't know that C# is really that much different from Python.
I haven't used it but I have the impression that it's sort of similar
under the skin.
Nope nope nope. C# is a statically typed, statically compiled (i.e., no
eval(...) or exec(...)), single-inheritance
JoeG schreef:
I disagree with your Tkinter vs. wxPython
decision. I tried a number of programs written with Tkinter and really
didn't like the interface. The program I helped develop is Windows
based and I knew that a program with the Tkinter interface would never
work as a cross platform
Bulba! [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Thanks to everyone for their responses, but it still doesn't work re
returning next() method:
class R3:
def __init__(self, d):
self.d=d
self.i=len(d)
def __iter__(self):
d,i = self.d, self.i
Alex Martelli wrote:
Steven Bethard [EMAIL PROTECTED] wrote:
(2) lambda a: a.lower()
My first thought here was to use str.lower instead of the lambda, but of
course that doesn't work if 'a' is a unicode object:
Right, but string.lower works (after an 'import string'). More
generally, maybe it
I am right in the middle of doing text parsing so I used your example as a
mental exercise. :-)
Here's a NDFA for your text:
b 0 1-9 a-Z , . + - '\n
S0: S0 E E S1 E E E S3 E S2 E
S1: T1 E E S1 E E E E E E T1
S2: S2 E E S2 E E E E E T2 E
S3: T3 E E S3 E E
Terry Reedy wrote:
This is the wrong test for what I and some others thought you were
asking.
The requirement for p to be an *iterable* and useable in code such as
'for
i in p' is that iter(p), not p itself, have a .next method, and
iter(p)
will. Try ip=iter(p) followed by ip.next and ip.next()
Bulba wrote:
OK, so what projects and why would you consider
Python:
1. clearly unsuitable
Large-scale scientific computing projects, such as numerical weather
prediction, where performance is critical. Python could be used as the
glue but not the guts, where Fortran 95 and C++ are more
Steven Bethard [EMAIL PROTECTED] wrote:
(3) self.plural = lambda n: int(n != 1)
Note that this is *almost* writable with def syntax. If only we could do:
def self.plural(n):
int(n != 1)
Not sure about the context, but maybe we could use, at class-level:
Ah! that is what the __future__ brings I guess.
Damn that progress making me outdated ;)
Python 2.2.3 ( a lot of extensions I use are stuck there , so I still
use it)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Gerhard Haering schreef:
I can understand your emotions here. OTOH it's typical for Germans
(and even more so French) to assume that everybody speaks their
language.
The same is true for English language speakers in my experience...
(E.g.: why is this international newsgroup in English only?)
[EMAIL PROTECTED] wrote:
...
array elements. Powers and subtractions in array operations seem to be
free in Fortran but very expensive in Python with Numeric.
Right, particularly raising to power: a good part of your observations
(not all) is accounted for by the fact that Python doesn't
M.E.Farmer wrote:
Ah! that is what the __future__ brings I guess.
Damn that progress making me outdated ;)
Python 2.2.3 ( a lot of extensions I use are stuck there , so I still
use it)
I'm also positively surprised how many cute little additions are there
every new Python version.
When I copy code from a source file into a Google Groups message, the
indentation is messed up, making my Python code illegal and all my code
ugly. Are there tricks to avoid this?
--
http://mail.python.org/mailman/listinfo/python-list
Cameron Laird [EMAIL PROTECTED] wrote:
...
Yippee! The martellibot promises to explain Unicode for Pythoneers.
http://groups-beta.google.com/group/comp.lang.python/msg/6015a5a05c206712
Uh -- _did_ I? Eeep... I guess I did... mostly, I was pointing to
Holger Krekel's very nice recipe (not
Phillip J. Eby [EMAIL PROTECTED] wrote:
Jp Calderone wrote:
I'd skip that, though. Your problem doesn't sound Metaclass! at
me.
I wonder if you could elaborate on your usage? Perhaps there's a
better
solution which doesn't involve metaclasses at all.
I suspect he could *maybe* get
Alex Martelli wrote:
Paul L. Du Bois [EMAIL PROTECTED] wrote:
def fn(gen):
Turns a generator expression into a callable.
def anonymous(*args): return gen.next()
return anonymous
def args():
Works with fn(); yields args passed to anonymous().
while True: yield
David Bolen wrote:
So for example, an asynchronous sequence of operations might be like:
d = some_deferred_function()
d.addCallback(lambda x: next_function())
d.addCallback(lambda blah: third_function(otherargs, blah))
d.addCallback(lambda x: last_function())
which to me is more
Steven Bethard [EMAIL PROTECTED] wrote:
Does that seem about right?
Yep!
P.S. That's so *evilly* cool!
We should have an Evilly Cool Hack of the Year, and I nominate Paul du
Bois's one as the winner for 2004. Do I hear any second...?
Alex
--
[EMAIL PROTECTED] (Alex Martelli) writes:
We should have an Evilly Cool Hack of the Year, and I nominate Paul du
Bois's one as the winner for 2004. Do I hear any second...?
The year's not over yet :).
--
http://mail.python.org/mailman/listinfo/python-list
David Bolen wrote:
Ian Bicking [EMAIL PROTECTED] writes:
The one motivation I can see for function expressions is
callback-oriented programming, like:
get_web_page(url,
when_retrieved={page |
give_page_to_other_object(munge_page(page))})
This is my primary use case for lambda's
Scott David Daniels [EMAIL PROTECTED] writes:
David Bolen wrote:
So for example, an asynchronous sequence of operations might be like:
d = some_deferred_function()
d.addCallback(lambda x: next_function())
d.addCallback(lambda blah: third_function(otherargs, blah))
David Bolen wrote:
Scott David Daniels [EMAIL PROTECTED] writes:
while test() != False:
...code...
I'm not sure I follow the error in this snippet...
The code is fat -- clearer is:
while test():
...code...
The right sequence using lambda is:
d =
Andrew Dalke [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
It's me wrote:
Here's a NDFA for your text:
b 0 1-9 a-Z , . + - '\n
S0: S0 E E S1 E E E S3 E S2 E
S1: T1 E E S1 E E E E E E T1
S2: S2 E E S2 E E E E E T2 E
S3: T3 E E S3 E
Freddie wrote:
I'm trying to parse a search string so I can use it for SQL WHERE
constraints, preferably without horrifying regular expressions. Uhh yeah.
If you're interested, I've written a function that parses query strings
using a customizable version of Google's search syntax.
Features
Andrew Dalke wrote:
It's me wrote:
Here's a NDFA for your text:
b 0 1-9 a-Z , . + - '\n
S0: S0 E E S1 E E E S3 E S2 E
S1: T1 E E S1 E E E E E E T1
S2: S2 E E S2 E E E E E T2 E
S3: T3 E E S3 E E E E E E T3
Now if I only had an NDFA for
In article [EMAIL PROTECTED],
Paul Rubin http://[EMAIL PROTECTED] wrote:
Peter Dembinski [EMAIL PROTECTED] writes:
If it has to be both reliable and secure, I suggest you used more
redundant language such as Ada 95.
That's something to think about and it's come up in discussions, but
probably
In article [EMAIL PROTECTED],
Christopher Koppler [EMAIL PROTECTED] wrote:
.
.
.
Manager culture is still very much mired in rituals that may in one form
or another go back to hunter-gatherer days (or maybe even further);
This is a 3 weeks old problem, but having found a solution (and having
looked for one here, finding only this message), I'm replying now.
From: Jive ([EMAIL PROTECTED])
Subject: Upgrade woes: Numeric, gnuplot, and Python 2.4
Date: 2004-12-11 18:45:10 PST
Here's my sitch:
I use gnuplot.py at
Dieter Maurer wrote:
We use pyUnit extensively and are mostly satisfied.
There is one essential problem we hit more often: setting up
and tearing down can take excessive time.
Often, we are forced to abandon the test independence
and let a complete set of tests share the main part of the fixture.
[EMAIL PROTECTED] wrote:
When I copy code from a source file into a Google Groups message, the
indentation is messed up, making my Python code illegal and all my
code
ugly. Are there tricks to avoid this?
Try putting a # at the start of every line. Everyone should
understand what you mean (and
Paul Rubin wrote:
You should write unit tests either way, but in Python you're relying
on the tests to find stuff that the compiler finds for you with Java.
As I wrote on my weblog a while ago, I suspect that this effect is
largely psychological. You jump through hoops, declaring types all over
On 2004-12-31, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
When I copy code from a source file into a Google Groups
message, the indentation is messed up, making my Python code
illegal and all my code ugly. Are there tricks to avoid this?
Try putting a # at the start
[EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
When I copy code from a source file into a Google Groups message,
the
indentation is messed up, making my Python code illegal and all my
code
ugly. Are there tricks to avoid this?
Try putting a # at the start of every line. Everyone
[EMAIL PROTECTED] (Bengt Richter) writes:
Closure is the name for the whole thing, apparently, not just the
environment the procedure body needs, which was the aspect that I
(mis)attached the name to.
Which brings me to the point where I'd welcome more flexibility in
writing to variables
John Machin [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Andrew Dalke wrote:
It's me wrote:
Here's a NDFA for your text:
b 0 1-9 a-Z , . + - '\n
S0: S0 E E S1 E E E S3 E S2 E
S1: T1 E E S1 E E E E E E T1
S2: S2 E E S2 E E E E E
For those curious about Trolltech's stance on Windows, here's what
Trolltech's License FAQ - Open Source Edition (
http://www.trolltech.com/developer/faqs/license_gpl.html ) has to say:
Why is there no Open Source (GNU GPL) version of Qt on Windows ?
We have regrettably not found a way of
Ian Bicking [EMAIL PROTECTED] writes:
But I do think there's other ways to approach this. Function
expressions could get really out of hand, IMHO, and could easily lead
to twenty-line expressions. That's aesthetically incompatible with
Python source, IMHO.
You can already write unaesthetic
Cameron Laird wrote:
In article [EMAIL PROTECTED],
Christopher Koppler [EMAIL PROTECTED] wrote:
.
.
.
Manager culture is still very much mired in rituals that may in one form
or another go back to hunter-gatherer days (or
Just a quick reminder for the laggards among us that you now have
approximately SEVEN HOURS in which to submit your proposals for a talk
at PyCon.
Thanks to all who have already taken the trouble to do so, and to the
rest of you: GET ON WITH IT!
happy-new-year-ly y'rs - steve
--
Steve Holden
On Fri, 2004-12-31 at 01:53, Steven Bethard wrote:
I thought it might be useful to put the recent lambda threads into
perspective a bit. I was wondering what lambda gets used for in real
code, so I grepped my Python Lib directory. Here are some of the ones I
looked, classified by how I
[EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
When I copy code from a source file into a Google Groups message,
the
indentation is messed up, making my Python code illegal and all my
code
ugly. Are there tricks to avoid this?
Try putting a # at the start of every line.
On Fri, 2004-12-31 at 13:03, [EMAIL PROTECTED] wrote:
When I copy code from a source file into a Google Groups message, the
indentation is messed up, making my Python code illegal and all my code
ugly. Are there tricks to avoid this?
Subscribe to the python-list@python.org mailing list. Take
Simo Melenius wrote:
map (def x:
if foo (x):
return baz_1 (x)
elif bar (x):
return baz_2 (x)
else:
global hab
hab.append (x)
return baz_3 (hab),
[1,2,3,4,5,6])
I think this would probably have to be
[EMAIL PROTECTED] (Cameron Laird) writes:
For a not-too-different variety of safety, I like Eiffel. Again,
Eiffel compilers are available nearly, but not entirely, everywhere.
Eiffel compilers tend to generate C code, and hence work on anything
with a C compiler. The question then becomes how
Adam DePrince wrote:
Lets not forget the real reason for lambda ... the elegance of
orthogonality. Why treat functions differently than any other object?
We can operate on every other class without having to involve the
namespace, why should functions be any different?
Yup. I think in most of
Adam DePrince wrote:
In sort, we must preserve the ability to create an anonymous function
simply because we can do so for every other object type, and functions
are not special enough to permit this special case.
Your reasoning makes sense... lambda enables you to create a function as
part of an
I have a Zope/Plone combination that I have been having POSKeyErrors
with for a while now. Are there any newsgroups that deal with Zope?
--
http://mail.python.org/mailman/listinfo/python-list
Hans Nowak wrote:
Adam DePrince wrote:
In sort, we must preserve the ability to create an anonymous function
simply because we can do so for every other object type, and functions
are not special enough to permit this special case.
Your reasoning makes sense... lambda enables you to create a
Steven Bethard [EMAIL PROTECTED] writes:
Simo Melenius wrote:
map (def x:
if foo (x):
return baz_1 (x)
elif bar (x):
return baz_2 (x)
else:
global hab
hab.append (x)
return baz_3 (hab),
Steven Bethard wrote:
Simo Melenius wrote:
map (def x:
if foo (x):
return baz_1 (x)
elif bar (x):
return baz_2 (x)
else:
global hab
hab.append (x)
return baz_3 (hab),
[1,2,3,4,5,6])
I think this would
Bob Horvath wrote:
I have a Zope/Plone combination that I have been having POSKeyErrors
with for a while now. Are there any newsgroups that deal with Zope?
No, but there is a mailing list - see zope.org
Also, try google searching for POSKeyError.
Richard
--
Steven Bethard [EMAIL PROTECTED] wrote:
...
Your reasoning makes sense... lambda enables you to create a function as
part of an expression, just like other types can be part of an
expression. However, by that same reasoning, maybe classes aren't
special enough either to warrant a
Adam DePrince wrote:
So, those are my thoughts on how lambdas are really used. If others
out there have real-life code that uses lambdas in interesting ways,
feel free to share them here!
Lets not forget the real reason for lambda ...
I really hoped you would point out the _real_
Dear list,
I am writing a Python extension module that needs a way to expose pieces
of a big C array to python. Currently, I am using NumPy like the following:
PyObject* res = PyArray_FromDimsAndData(1, int*dim, PyArray_DOUBLE,
char*buf);
Users will get a Numeric Array object and can change
Reinhold Birkenfeld wrote:
Freddie wrote:
Happy new year! Since I have run out of alcohol, I'll ask a question that I
haven't really worked out an answer for yet. Is there an elegant way to turn
something like:
moo cow farmer john -zug
into:
['moo', 'cow', 'farmer john'], ['zug']
I'm trying to
M.E.Farmer [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Terry Reedy wrote:
will. Try ip=iter(p) followed by ip.next and ip.next() instead.
Does that mean if you dont't call iter(() on your instance or have a
next() method you can't do this:
p=R3('eggs')
for i in p:
print
Terry ,
Thank you for the explanation . That is much clearer now, I have played
a bit with generators but have never tried to create a custom iterator.
I am just now getting into the internals part of python objects... this
langauage is still amazing to me!
The reason I asked the question was
Erik Bethke wrote:
# setup.py
from distutils.core import setup
import py2exe
setup(console=[myscript.py])
#
python setup.py py2exe
-Knio
Erik glad to see you were able to track it down.
Have you been succesful in making the changes they mentioned?
M.E.Farmer
--
Adam DePrince [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
In sort, we must preserve the ability to create an anonymous function
simply because we can do so for every other object type, and functions
are not special enough to permit this special case.
Please show me how to
1 - 100 of 116 matches
Mail list logo