Slashdot Mirror


User: chromatic

chromatic's activity in the archive.

Stories
0
Comments
2,306
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 2,306

  1. Re:Scalability? on Ruby 1.9.0 Released · · Score: 1

    Heck, let's be honest - the Windows implementation was not what you'd call complete (or at least wasn't the last time I bothered to check).

    Was this 1999? Perl's had first-class support on Windows since at least 5.6.0.

  2. Homaridae on Researchers Simulate Building Block of Rat's Brain · · Score: 1

    I thought lobsters were first.

  3. Re:Good and bad news on GNU Octave 3.0 Released After 11 Years · · Score: 1

    I'm familiar with both, and I have no problem with them as features, but I don't consider them "exceptionally simple", syntax-wise. Don't get me started on double-underscores and slots....

  4. Re:Good and bad news on GNU Octave 3.0 Released After 11 Years · · Score: 1

    no one can deny that Python has an extremely simple syntax.

    Have you ever used decorators or nested list comprehensions?

  5. Re:Much Thanks to Mr. Wall on Perl 5.10, 20 Year Anniversary · · Score: 1

    Knowing my own limitations with keeping track of variable names, etc. I would personally prefer a more orderly language like Java for larger programs.

    Hmm. How does Java make it easier to keep track of variable names? My best guess is that Foo foo = new Foo(); is a mnemonic device. "Oh, I guess it must really be a Foo!"

  6. Re:Puzzle Quest on What Is Your Game of the Year? · · Score: 1

    Choosing the right spells is difficult. It helps if you've captured enough enemies to research a few different types. I've found that losing a combat then rearranging the available spells can make a difficult combat much easier.

  7. Puzzle Quest on What Is Your Game of the Year? · · Score: 2, Interesting

    I've spent more hours playing Puzzle Quest for my DS than I care to mention, and I haven't even finished yet.

  8. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 1

    I'm a Perl 6 and Parrot developer, and I was speaking hypothetically, as if I weren't a Parrot developer and were instead helping to implement Perl 6 on the DLR.

  9. Re:Firefox Seems To Losing Its Luster on First Look At Firefox 3.0 Beta 2 · · Score: 1

    Whenever I see statements like this, I ask myself, "Has this person ever done any real software development?"

    Heh. You actually have to ask?

  10. Re:or use a modern allocation scheme on First Look At Firefox 3.0 Beta 2 · · Score: 1

    How does a generational GC solve fragmentation? (I can imagine that a copying generational GC helps, but unless you sbrk and never malloc, I don't see how you can avoid fragmentation.)

  11. Re:Memory Leaks? on First Look At Firefox 3.0 Beta 2 · · Score: 2, Informative

    It would take a really bad OS to make memory fragmentation a problem, since memory address pointers are virtualized....

    Actual memory addresses aren't. If you allocate 1,000 pages, free a few in the middle, and try to allocate another thousand contiguous pages, you won't get them a few from here and a few from there.

    I'm sure it's possible to stitch together a byte here, a byte there, and so on in your VMM, but that would be a lot of overhead and you'd need to be pretty good at packing algorithms to make that work. I'm also not sure that malloc() has to return contiguous memory.

  12. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 1

    As long as parrot requires some baseline functionally before you can join the club, life will be okay.

    If someone writes a bad PMC by hand, there's not much Parrot can do to fix that. What we can do is make it sufficiently easy to write a good PMC that people do that instead.

    Likewise we hope that the standard features that Parrot provides, such as method resolution and control flow and compiler building, are sufficiently powerful and flexible that you can reuse them to build a new language, or customize them in a way that's still compatible with the rest of Parrot.

    It is the "If $LANGUAGE_X supports a keyed lookup operation, then..." that makes me nervous. How can I test that if there is no defined behavior?

    Perhaps we're talking past each other. I mean the language's syntax. For example, there are no associative arrays in C as a fundamental data type, while there are indexed arrays. It doesn't hurt C on Parrot to use a PMC that has keyed access, but you can't access that PMC by key with C's normal syntax; you need some sort of function to do it for you.

    All PMCs have a vtable entry that allows you to access a PMC by key, but not all PMCs are aggregate containers or have some other semantically meaningful behavior for accessing a PMC by a key. Those that don't throw exceptions, but they don't crash Parrot.

  13. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 2, Informative

    what is in it for me? Why should I care?

    Having access to the CPAN from other languages would be useful (Ruby programmers take note). I want Pygame and Pyglet available to Perl 6 as well.

    If I'm PHP, why should I compile to PIR?

    Library support, primarily. mod_php is well-understood and widely deployed. However, it's possible that the Parrot security model may make mod_parrot more appealing to deploy than mod_php.

    What is the fundamental "unit" of a library/application compiled in PIR. In .NET you deal in assemblies. In PIR, what do you deal in?

    There's no real formal name, but a PBC file is as close as you get. It's just a bunch of bytecode. As yet we haven't decided on any formal interface that it needs to support.

    Where is the boundary between something written in PHP and something in Perl? Is it a function? A class? A module?

    It can be any of those. For example, my little Scheme-like language has self-hosted tests. They use a testing library I wrote in PIR. The testing library provides a series of multimethods that my language can call as if they were native functions -- and my language doesn't support multi-dispatch!

    How does PIR handle the clash between objects and classes? Can I pass a blessed object created in perl to my PHP app?

    Yes. The semantics of how that object will behave depends on its class, but as long as PHP on Parrot and Perl on Parrot use Parrot's calling conventions and its PMC interfaces for things like calling methods and creating objects, each language can have its own special semantics and can use objects defined in other languages.

    What about namespace issues and how does PIR reconcile against language that have piss poor namespace support like PHP?

    Each high-level language has its own top-level namespace. I imagine that the PHP implementation just lobs some three-thousand functions into that namespace, where Perl 6 stores things differently.

    What about all the cool hashtable/hashref stuff that perl has? How will that work on something like PHP?

    Data structures created in Perl and passed into PHP will have Perl semantics for all equivalent operations performed in PHP. If PHP supports a keyed lookup operation, Parrot will perform that operation on the data structure. How that structure's underlying object handles keyed lookup is up to the object, and it'll have Perl semantics.

    What about inheritance? Can I derive a class in perl from a class written in Ruby?

    Yes. (I don't know how well that works right now; I don't know if anyone has specifically tried it.)

    What about debugging? If something chokes in my PHP library, will parrot let me see the PHP symbol table AND my python symbol table?

    As long as the debugger knows about Parrot, it should.

    How will any of this be useful without a very smart IDE? It is hard enough to keep track of large applications written in Perl because of the lacking tool support. If I'm calling a function/assembly written in PHP, am I now going to have to hop between to languages to figure it all out?

    Reconstructing a language from PBC is non-trivial, but one of the goals of Parrot (and Perl 6) is to encourage better tool support by making it easier to plug an editor into the VM somehow. The answer is "it depends".

    What is the baseline "your language needs to support XYZ before it works in PIR"? Or is this thing so low, the only thing I can bank on is a string? Does it define, for example, how and when a string might get cast as an integer

  14. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 1

    If you do download the tarball, feel free to join #parrot on irc.perl.org. There's a fair bit of code, and having someone onhand to answer your questions can make it much easier to start!

  15. Re:Double digit version #s aren't alphanumerically on Perl 5.10, 20 Year Anniversary · · Score: 1

    Perl version numbers are dotted triplets, much like IP addresses can be dotted quads. If there were such a thing as an official version number, it would be 5.001000.

  16. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 1

    Actually the CLR handles dynamic languages quite well.

    It's improving, yes. By the time we added sufficient features to the DLR to handle Perl 6 well, though, we'd have reinvented Parrot on the CLR -- and the DLR didn't exist when we started.

  17. Re:Oh dear. on Perl 5.10, 20 Year Anniversary · · Score: 1

    What cost of interpolation? The ppcodes are (basically) the same in both cases. There are variable accesses and concatenations.

    Interpolation is a syntactic benefit for coders. The VM doesn't care.

  18. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 1

    ... but as far as actual coding is concerned, a (interpreter) project that doesn't release for so long *is* *vaporware*.

    We've released twelve stable versions of Parrot this year alone, including one just yesterday.

  19. Re:Switch statements are syntactic sugar on Perl 5.10, 20 Year Anniversary · · Score: 1

    Why it's not default by now, I can't say.

    Backwards compatibility.

    It's on by default in Perl 6 for all programs executed from files, not as one-liners on the command line.

  20. Re:Hmmmmmm on Perl 5.10, 20 Year Anniversary · · Score: 1

    You could have some Python, some Perl, and some Scheme code (eventually) executing together.

    Eventually? Today.

  21. Re:Features and whatnot. on Perl 5.10, 20 Year Anniversary · · Score: 1

    So, for example, I want to test $me->boss->wife->is_cute() while accounting for the possibility of unemployment or celibacy. This will either turn into an ugly one-liner with lots of "&&" and redundant calls, or the use of temporary variables.

    I saw a lightning talk about overloaded undef last year at YAPC::EU, so you might track down Juerd Waalboer (perhaps on PerlMonks) to see if he can share his trick. If you absolutely must call all of those methods, that may work.

    If it were me, I'd still write eval { $me->boss->wife->is_cute() } and check for the exception, though.

  22. Re:Features and whatnot. on Perl 5.10, 20 Year Anniversary · · Score: 1

    You're welcome, but I think I'll work on it anyway. You can use it when we're finished, if you like!

  23. Re:Features and whatnot. on Perl 5.10, 20 Year Anniversary · · Score: 1

    Stop doing things, just because you can. Do something else -- and I don't mean that franken-project Perl 6.

    I was going to work on Perl 6 today, but because some random jackass on the Internet thinks I shouldn't....

  24. Re:Features and whatnot. on Perl 5.10, 20 Year Anniversary · · Score: 1

    Me, I'm still waiting for the "call a method on this object if defined" operator.

    Are you looking for eval BLOCK around the chained method calls?

  25. Re:Switch statements are syntactic sugar on Perl 5.10, 20 Year Anniversary · · Score: 1

    Look at the smart match operator in Perl 5.10. I think you'll like it.