Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-dev] Some minor changes to the code?

Hi Wes!

> Sorry, I forgot to mention three points:
>
> - As you may know, Monday is supposed to be the last day to check in any
> code for 1.1, so a timely submission would be appreciated.

Okay. So I will create the patches this morning and submit them to the bug system. No problem!

> - We'd start by running the ajc test suite, so you might want to do that
> to make sure your patch does not cause any new test failures. (For information on running the test suite, see modules/tests/readme-*.html
> in the sources.)

The changes do not break any existing test cases on my machine.

> - test cases are also welcome, for the API changes and/or for the classloader if you decide to contribute it.

Because most of the changes are setting a method from private, package or protected to public I haven't added any test cases.

The test cases for the class loader aren't yet in a state for contribution. So in general I would contribute the classloader to the project. But today seems to be a bit too early. Sorry!

Thanks again!
-Martin




Would you submit a bug (feature request), create a patch, and attach
the patch to the bug?  That way Jim/Erik can inspect and apply the patch
to evaluate the question.  For an example, see Adrian's bug 29769

 http://bugs.eclipse.org/bugs/show_bug.cgi?id=29769

It creates a patch for each module (i.e., for each eclipse project)
because that's a good way for us to apply them in Eclipse.

btw, are you contributing the class loader to the project? or is it
only that you want the hooks for your class loader to work?  A basic
load-time weaver is one of the features planned for 1.1.

Thank you -
Wes

Martin Lippert wrote:

Hi!

I am not sure whether this is the right place to discuss this but I hope.

I have implemented a special class loader for dynamic weaving at class
loading time using the weaver project from AspectJ. Therefore I had to
make only a few changes to the original sources which I would love to
put back into the project.

Would that be possible? All Tests are unchanged and still produce a
green bar.

The changes are:

-> org.aspectj.weaver.bcel.BcelObjectType:
method "resetState" is now public.

-> org.aspectj.weaver.bcel.ClassPathManager:
I extracted a public method "addPath" out of the constructor to enable
late adding of pathes.

-> org.aspectj.weaver.bcel.BcelWorld:
1.) method "addSourceObjectType" is now public
2.) I added a method
public void addPath (String name) {
  classPath.addPath(name);
}

-> org.aspectj.weaver.bcel.BcelWeaver:
1.) method "weave(ResolvedTypeX onType)" is now public
2.) I added a method similar to "weave(UnwovenClassFile classFile,
BcelObjectType classType)" which does not include the calls to dump the
changed or unchanged file contents. The method returns null, if the
class is not changed by the method or the LazyClassGen object if the
class os changed by the weaving process.

Thanks for lookig at it!!! Is this the right way to contribute something
to the project or should I do it another way?

Best regards,
Martin

_______________________________________________
aspectj-dev mailing list
aspectj-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/aspectj-dev

_______________________________________________
aspectj-dev mailing list
aspectj-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/aspectj-dev

_______________________________________________
aspectj-dev mailing list
aspectj-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/aspectj-dev



Back to the top