Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Re: Implementing (elisp-like) buffers in Perl 6: how to do buffer-localisation of arbitrary package variables?

by samtregar (Abbot)
on Mar 29, 2003 at 18:27 UTC ( [id://246629]=note: print w/replies, xml ) Need Help??


in reply to Re: Implementing (elisp-like) buffers in Perl 6: how to do buffer-localisation of arbitrary package variables?
in thread Implementing (elisp-like) buffers in Perl 6: how to do buffer-localisation of arbitrary package variables?

Frankly, I doubt it. The Perl 5 object system is among the most flexible in the programming world. What exactly are you missing that you think you'd need to implement buffers?

-sam

  • Comment on Re: Re: Implementing (elisp-like) buffers in Perl 6: how to do buffer-localisation of arbitrary package variables?

Replies are listed 'Best First'.
Re: Implementing (elisp-like) buffers in Perl 6: how to do buffer-localisation of arbitrary package variables?
by jonadab (Parson) on Mar 30, 2003 at 22:22 UTC
    The Perl 5 object system is among the most flexible in the programming world.

    Maybe if you compare it to C++ and Java. Sure, it's Turing-complete, so theoretically anything could be implemented in it. But I prefer to keep my sanity. The Perl6 object model will have a number of substantial improvements, and I'll be looking forward to that. Yes, I know it will be a while yet, but as the Apocalypsen roll in, more and more of the design (at least) will be clear. It may even be possible to start before Perl6 is released as such.


    for(unpack("C*",'GGGG?GGGG?O__\?WccW?{GCw?Wcc{?Wcc~?Wcc{?~cc' .'W?')){$j=$_-63;++$a;for$p(0..7){$h[$p][$a]=$j%2;$j/=2}}for$ p(0..7){for$a(1..45){$_=($h[$p-1][$a])?'#':' ';print}print$/}
      Maybe if you compare it to C++ and Java.

      Or Ada. Or Python. Or Ruby. Should I list all the languages I know? Would that make Perl's OO support any more or less flexible?

      You didn't answer my question. What precisely is missing from Perl 5's object system that is keeping you from implementing buffers now?

      Don't get me wrong, I'm looking forward to Perl 6 too. But most of what I've seen looks like syntactic sugar. Are there really applications that can be written in Perl 6 that simply cannot be written in Perl 5? I won't believe it until you produce concrete evidence.

      -sam

        Or Ada. Or Python. Or Ruby.

        I tried Python and didn't like it, although I didn't get far enough to know how strong the object model is, because the B&D type system turned me right off. I can't comment on Ada or Ruby except to say that neither is known for being object oriented. Try programming a medium-sized project in Inform for example, and then come back and look at Perl5's object system.

        Are there really applications that can be written in Perl 6 that simply cannot be written in Perl 5?

        Why, are you in some kind of special hurry?

        No, of course not. For that matter there is nothing that can be written in Perl 6 that simply cannot be written in assembly language. Congratulations, you've discovered Turing completeness. It's a matter of how much time and effort I want to spend creating a module to make programming easier in a language that in three years will be obsolete. (By the time I finished we'd be more than halfway there... it won't take me one quarter as long to do it in Perl6.)

        What precisely is missing from Perl 5's object system that is keeping you from implementing buffers now?

        Just for starters how about sane syntax, a decent inheritance mechanism, traits and properties, and the ability for methods to determine exactly what context they've been called in, and a lot of stuff that makes anonymous routines easier to work with? How about the rest of the language being more geared toward expecting stuff to be object-oriented? How about that Perl5's object system is such a convoluted hack that I only barely understand it, whereas just from reading the Apocalypse articles I already have a very firm grasp of Perl6's object model, because it makes sense.

        Yeah, I could fake a lot of that with existing mechanisms (hashes, especially), but it'll be a whole lot easier when it's built into the language. Perl5 is pretty cool, but Perl6 is going to rock significantly.


        for(unpack("C*",'GGGG?GGGG?O__\?WccW?{GCw?Wcc{?Wcc~?Wcc{?~cc' .'W?')){$j=$_-63;++$a;for$p(0..7){$h[$p][$a]=$j%2;$j/=2}}for$ p(0..7){for$a(1..45){$_=($h[$p-1][$a])?'#':' ';print}print$/}

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://246629]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (5)
As of 2024-04-16 17:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found