|
From: <fra...@us...> - 2009-07-22 04:08:50
|
Revision: 1767
http://javapathfinder.svn.sourceforge.net/javapathfinder/?rev=1767&view=rev
Author: frankrimlinger
Date: 2009-07-22 04:08:47 +0000 (Wed, 22 Jul 2009)
Log Message:
-----------
Cleaned up code involving detection of instantiated and automatic expressions. The point of view now is that an expression is instantiated if it contains no free state variable, and automatic if it is instantiated and contains no ModuleInvocationSym. This will probably be tweaked during testing, but it is good to start out with something that is at least conceptual.
Updated ANEWARRAY, NEW, NEWARRAY, and MULTIANEWARRAY to push the class name on the heap as a ClassNameSym, as opposed to the component name, in the case of arrays, as an Other.
Updated AASTORE to fetch the class name from the heap and then convert to the component name, which is used in turn to check assignment compatibility. Per 1766, the operation is accomplished with the makeComponentClass rulekey, with corresponding rule just stripping the ultimate "[]" from concrete arguments.
Removed the pushRefH from AASTORE and ARRAYLENGTH. pushRefH is now totally removed from the code base.
Next TODO: rewrite native abstraction of Object_MangoFormal.getClass() to return the ClassNameSym whose name is the name of the desired class. This is consistent with Rev 1766, in that ClassNameSym now has type <object>. But the suggestion in Rev 1766 to return (valueH (refH '@this ^className) '@inputHeap )) is incorrect, since this expression is non-canonical and unlikely to evaluate to the canonical ClassNameSym. So its best to just grab the bull by the horns and return the ClassNameSym in the first place.
Revision Links:
--------------
http://javapathfinder.svn.sourceforge.net/javapathfinder/?rev=1766&view=rev
http://javapathfinder.svn.sourceforge.net/javapathfinder/?rev=1766&view=rev
Modified Paths:
--------------
branches/mango/Mango/Mango/src/mango/module/definition/sym/ParamSym.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/Automatic.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/AutomaticLocalVar.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/AutomaticThis.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/Instantiated.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/InstantiatedLocalVar.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/InstantiatedOpVar.java
branches/mango/Mango/Mango/src/mango/ruleRequirement/naturalLanguage/InstantiatedThis.java
branches/mango/Mango/Mango/src/mango/worker/workFlow/model/HitemUtil.java
branches/mango/Mango/Mango/src/mango/worker/workFlow/msg/ShowTypeRequestMsg.java
branches/mango/Mango/javapathfinder-mango-bridge/mango/scanner/bytecode/AASTORE.java
branches/mango/Mango/javapathfinder-mango-bridge/mango/scanner/bytecode/ANEWARRAY.java
branches/mango/Mango/javapathfinder-mango-bridge/mango/scanner/bytecode/ARRAYLENGTH.java
branches/mango/Mango/javapathfinder-mango-bridge/mango/scanner/bytecode/MULTIANEWARRAY.java
branches/mango/Mango/javapathfinder-mango-bridge/mango/scanner/bytecode/NEW.java
branches/mango/Mango/javapathfinder-mango-bridge/mango/scanner/bytecode/NEWARRAY.java
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|