[jboss-jira] [JBoss JIRA] Created: (JBAOP-744) AbstractAopMetaDataDeployer.FakeComponentUnit.getScope() does not create a new scope

Kabir Khan (JIRA) jira-events at lists.jboss.org
Tue Aug 4 09:12:30 EDT 2009


AbstractAopMetaDataDeployer.FakeComponentUnit.getScope() does not create a new scope
------------------------------------------------------------------------------------

                 Key: JBAOP-744
                 URL: https://jira.jboss.org/jira/browse/JBAOP-744
             Project: JBoss AOP
          Issue Type: Bug
      Security Level: Public (Everyone can see)
            Reporter: Kabir Khan
            Assignee: Kabir Khan
             Fix For: 2.1.4.GA, 2.2.0.GA


	From: 	smarlow at redhat.com
	Subject: 	ScopeKey + AbstractAopMetaDataDeployer.FakeComponentUnit.getScope()...
	Date: 	4 August 2009 02:07:52 BST
	To: 	kkhan at redhat.com
	Reply-To: 	smarlow at redhat.com

Kabir,

I am still getting up to speed on the mc internals and am looking at different uses of ScopeKey.  I came across the following code fragment and wanted to ping you about it.  For the case where the "scope" variable is null, I don't see where we are assigning "key" to "scope" and we would therefore return null to the caller (whom is probably expecting the new ScopeKey value).


     // org.jboss.aop.asintegration.jboss5.AbstractAopMetaDataDeployer.FakeComponentUnit

     ScopeKey getScope()
     {
        if (scope == null)
        {
           ScopeKey key = parent.getScope().clone();
           key.removeScopeLevel(CommonLevels.INSTANCE);
           key.addScope(CommonLevels.INSTANCE, bmd.getName());
        }
        return scope;
     }

The JBoss AOP unit tests still succeed with a small code change to return the new ScopeKey instead of null.

Scott

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list