Re: Adding a Builtin to EUPHORIA

new topic     » goto parent     » topic index » view thread      » older message » newer message
mattlewis said...
jimcbrown said...

I don't think [regex] would have been that much slower. It's how we handle a lot of the stuff in the stdlib, like msgboxes and mmap.

There would be *a lot* more manual memory management. And not just the stuff we have to do to convert a sequence into a C string, but a lot of the structures and things that get passed around. Stuff that goes right on the stack in C (very fast) would be allocated on the heap. For one off stuff, it's not a big deal, but regexes are often used (I know I do) for processing lots of data, over and over.

I don't understand why the existing type system (with regexes being a unique type) wouldn't work with PCRE being a shared library. Jeremy easily went back and forth on this in the code when we were debating this issue.

mattlewis said...
jimcbrown said...
mattlewis said...

Requiring a separate library to be distributed would be crazy.

Agreed, if it had to be distributed separately. I don't see it being a big deal to have to ship the one PCRE library with Euphoria though. You ever see how many dlls a Windoze installation of Python comes with?

Except one of the selling points of euphoria is how easy it is to distribute stuff. You can easily put it all together into a single executable (plus whatever else you add, of course). But requiring an additional runtime to go along with it is a dangerous and painful path (MSVCRT, VBRUN, etc).

Matt

We can still do that. Just carry around both the shared and static versions of the PCRE library. If py2exe can turn a Python app (and all its required runtimes) into a single executable, I don't see why we'd have so much trouble with just one library.

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu