Re: AOP and parametric polymorphism

From: Craig Chambers (chambers@cs.washington.edu)
Date: Sat Nov 23 2002 - 10:12:09 PST

  • Next message: Keunwoo Lee: "Hydro ECOOP submission redux"

    My opinion is that I'm interested in lots of the expressive power that AOP (and
    several other things predating AOP) offer. I think the problems brought up
    below are not necessarily because of too much power, but rather too little
    control or modularity. I think part of Keunwoo's point was along these lines.
    Not "AOP is bad" but "uncontrolled hacking is bad, in any system, but controlled
    extensibility could be good, depending on the tradeoffs."

    -- Craig

    Andrei Alexandrescu wrote:
    >
    > ----- Original Message -----
    > From: "Keunwoo Lee" <klee@cs.washington.edu>
    > To: <cecil@cs.washington.edu>
    > Sent: Tuesday, November 05, 2002 15:05
    > Subject: Re: AOP and parametric polymorphism
    >
    > > And if AOP is metaprogramming, then its power is essentially limited only
    > > by the expressiveness of the particular metalinguistic constructs you
    > > provide. In a sufficiently expressive AOP system, you could express
    > > *every* language extension as an aspect. And, indeed, that's what you can
    > > do in Lisp, where every program is an s-expression and you can execute any
    > > computable function over a program.
    > >
    > > Therefore, the question is not: "How expressive is AOP?" Rather, one
    > > should ask: "How expressive do you want AOP to be, and what constructs
    > > give that expressiveness while retaining modular reasoning, etc.?" My
    > > opinion of AspectJ is that it seems to give you too much power (or the
    > > wrong kind) and not enough modular reasoning.
    >
    > So indeed. In a break during my talk, I was talking to an older guy, and he
    > told me: "I've done something similar with InterLISP, which has :before and
    > :after functions (invoked automatically before/after calls), and it was a
    > maintenance nightmare. Every so often, something we knew worked did not work
    > anymore because someone had added some :before/:after function."
    >
    > Another guy in the audience, when I said AOP can "intercept" variable
    > accesses in read and write, and asked "What do you think you can do with
    > this?" said: "Break encapsulation?" (I was expecting something along the
    > lines of uninitialized access detection, lazy initialization etc.)
    >
    > Looks like AOP is good at enforcing static global policies. Threading, error
    > handling, and tracing are the classic examples. For these, other paradigms
    > offer only awkward solutions. Aside from those, however, it seems like not
    > much other compelling examples for AOP are appearing!
    >
    > Andrei
    >
    > _______________________________________________
    > Cecil mailing list
    > Cecil@cs.washington.edu
    > http://mailman.cs.washington.edu/mailman/listinfo/cecil
    _______________________________________________
    Cecil mailing list
    Cecil@cs.washington.edu
    http://mailman.cs.washington.edu/mailman/listinfo/cecil



    This archive was generated by hypermail 2.1.5 : Sat Nov 23 2002 - 10:06:44 PST