# HG changeset patch # User vranyj1 # Date 1325437390 0 # Node ID a2e2c13b0ff6fa89cdff5451c139958d8490d4c9 # Parent 1a973b2da424618a678afa9699c9ed3f3845eb7b Some testing methods diff -r 1a973b2da424 -r a2e2c13b0ff6 src/JavaClass.st --- a/src/JavaClass.st Sun Jan 01 14:47:13 2012 +0000 +++ b/src/JavaClass.st Sun Jan 01 17:03:10 2012 +0000 @@ -1889,6 +1889,22 @@ "Created: / 20-12-2010 / 21:53:30 / Jan Vrany " ! +isJavaWrapperClass + "Returns true, iff receiver is one of the Java wrapper classes or String" + + name == #'java/lang/Byte' ifTrue:[^true]. + name == #'java/lang/Short' ifTrue:[^true]. + name == #'java/lang/Integer' ifTrue:[^true]. + name == #'java/lang/Long' ifTrue:[^true]. + name == #'java/lang/Character' ifTrue:[^true]. + name == #'java/lang/Boolean' ifTrue:[^true]. + name == #'java/lang/String' ifTrue:[^true]."/Not really a wrapper, but..." + + ^false. + + "Created: / 26-12-2011 / 22:03:43 / Jan Vrany " +! + isUnresolved "return true, if the receiver is unresolved; javaClasses are never; JavaUnresolvedClasses are always" diff -r 1a973b2da424 -r a2e2c13b0ff6 src/LookupIntegrationTestsResource.st --- a/src/LookupIntegrationTestsResource.st Sun Jan 01 14:47:13 2012 +0000 +++ b/src/LookupIntegrationTestsResource.st Sun Jan 01 17:03:10 2012 +0000 @@ -97,6 +97,13 @@ projectDir ^ projectDir +! + +resources + + ^ { JavaInitializedResource } + + "Created: / 01-01-2012 / 17:24:20 / Jan Vrany " ! ! !LookupIntegrationTestsResource class methodsFor:'running'! diff -r 1a973b2da424 -r a2e2c13b0ff6 src/Make.proto --- a/src/Make.proto Sun Jan 01 14:47:13 2012 +0000 +++ b/src/Make.proto Sun Jan 01 17:03:10 2012 +0000 @@ -1,7 +1,7 @@ # $Header$ # # DO NOT EDIT -# automagically generated from the projectDefinition: stx_libjava at 2011-12-31 11:24:50.341. +# automagically generated from the projectDefinition: stx_libjava at 2012-01-01 18:01:40.468. # # Warning: once you modify this file, do not rerun # stmkmp or projectDefinition-build again - otherwise, your changes are lost. @@ -133,7 +133,6 @@ # BEGINMAKEDEPEND --- do not remove this line; make depend needs it -$(OUTDIR)Benchmarks__JavaLookup.$(O) Benchmarks__JavaLookup.$(H): Benchmarks__JavaLookup.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)Java.$(O) Java.$(H): Java.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)JavaAnnotation.$(O) JavaAnnotation.$(H): JavaAnnotation.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)JavaAnnotationContainer.$(O) JavaAnnotationContainer.$(H): JavaAnnotationContainer.st $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) @@ -214,7 +213,7 @@ $(OUTDIR)JavaMethodDeclaratorNode.$(O) JavaMethodDeclaratorNode.$(H): JavaMethodDeclaratorNode.st $(INCLUDE_TOP)/stx/libjava/JavaNode.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)JavaMethodDescriptor.$(O) JavaMethodDescriptor.$(H): JavaMethodDescriptor.st $(INCLUDE_TOP)/stx/libjava/JavaDescriptor.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)JavaMethodNode.$(O) JavaMethodNode.$(H): JavaMethodNode.st $(INCLUDE_TOP)/stx/libjava/JavaNode.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) -$(OUTDIR)JavaPetitParser.$(O) JavaPetitParser.$(H): JavaPetitParser.st $(INCLUDE_TOP)/squeak/petitparser/PPCompositeParser.$(H) $(INCLUDE_TOP)/squeak/petitparser/PPDelegateParser.$(H) $(INCLUDE_TOP)/squeak/petitparser/PPParser.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libbasic/ReadStream.$(H) $(INCLUDE_TOP)/stx/libbasic/PositionableStream.$(H) $(INCLUDE_TOP)/stx/libbasic/PeekableStream.$(H) $(INCLUDE_TOP)/stx/libbasic/Stream.$(H) $(INCLUDE_TOP)/stx/libjava/PPJavaNode.$(H) $(STCHDR) +$(OUTDIR)JavaPetitParser.$(O) JavaPetitParser.$(H): JavaPetitParser.st $(INCLUDE_TOP)/squeak/petitparser/PPCompositeParser.$(H) $(INCLUDE_TOP)/squeak/petitparser/PPDelegateParser.$(H) $(INCLUDE_TOP)/squeak/petitparser/PPParser.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(INCLUDE_TOP)/stx/libjava/PPJavaNode.$(H) $(INCLUDE_TOP)/stx/libbasic/ReadStream.$(H) $(INCLUDE_TOP)/stx/libbasic/PositionableStream.$(H) $(INCLUDE_TOP)/stx/libbasic/PeekableStream.$(H) $(INCLUDE_TOP)/stx/libbasic/Stream.$(H) $(STCHDR) $(OUTDIR)JavaStringRef2.$(O) JavaStringRef2.$(H): JavaStringRef2.st $(INCLUDE_TOP)/stx/libjava/JavaRef2.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)JavaTypeNode.$(O) JavaTypeNode.$(H): JavaTypeNode.st $(INCLUDE_TOP)/stx/libjava/JavaNode.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) $(OUTDIR)JavaUnhandledExceptionError.$(O) JavaUnhandledExceptionError.$(H): JavaUnhandledExceptionError.st $(INCLUDE_TOP)/stx/libjava/JavaError.$(H) $(INCLUDE_TOP)/stx/libbasic/Error.$(H) $(INCLUDE_TOP)/stx/libbasic/Exception.$(H) $(INCLUDE_TOP)/stx/libbasic/GenericException.$(H) $(INCLUDE_TOP)/stx/libbasic/Object.$(H) $(STCHDR) diff -r 1a973b2da424 -r a2e2c13b0ff6 src/Make.spec --- a/src/Make.spec Sun Jan 01 14:47:13 2012 +0000 +++ b/src/Make.spec Sun Jan 01 17:03:10 2012 +0000 @@ -1,7 +1,7 @@ # $Header$ # # DO NOT EDIT -# automagically generated from the projectDefinition: stx_libjava at 2011-12-31 11:24:49.091. +# automagically generated from the projectDefinition: stx_libjava at 2012-01-01 18:01:38.911. # # Warning: once you modify this file, do not rerun # stmkmp or projectDefinition-build again - otherwise, your changes are lost. diff -r 1a973b2da424 -r a2e2c13b0ff6 src/abbrev.stc --- a/src/abbrev.stc Sun Jan 01 14:47:13 2012 +0000 +++ b/src/abbrev.stc Sun Jan 01 17:03:10 2012 +0000 @@ -50,7 +50,7 @@ JavaObjectDictionary JavaObjectDictionary stx:libjava 'Languages-Java-Support' 0 JavaPackage JavaPackage stx:libjava 'Languages-Java-Support' 0 JavaParseResult JavaParseResult stx:libjava 'Languages-Java-Parser' 0 -JavaParserNavigationTests JavaParserNavigationTests stx:libjava 'Languages-Java-Tests' 0 +JavaParserNavigationTests JavaParserNavigationTests stx:libjava 'Languages-Java-Tests' 1 JavaParserTestCase JavaParserTestCase stx:libjava 'Languages-Java-Tests' 1 JavaParserTests JavaParserTests stx:libjava 'Languages-Java-Tests' 1 JavaPopUpView JavaPopUpView stx:libjava 'Languages-Java-Views-Support' 2 @@ -75,8 +75,8 @@ JavaUnresolvedConstant JavaUnresolvedConstant stx:libjava 'Languages-Java-Reader-Support' 0 JavaView JavaView stx:libjava 'Languages-Java-Views-Support' 2 JavaZipSupport JavaZipSupport stx:libjava 'Languages-Java-Support' 0 -LookupIntegrationTests LookupIntegrationTests stx:libjava 'Languages-Java-Experiments-Lookup-Tests' 1 -LookupIntegrationTestsResource LookupIntegrationTestsResource stx:libjava 'Languages-Java-Experiments-Lookup-Tests' 3 +LookupIntegrationTests LookupIntegrationTests stx:libjava 'Languages-Java-Experiments-Tests' 1 +LookupIntegrationTestsResource LookupIntegrationTestsResource stx:libjava 'Languages-Java-Experiments-Tests' 3 MPXJTests MPXJTests stx:libjava 'Languages-Java-Tests-Libraries' 1 PPJavaNode PPJavaNode stx:libjava 'Languages-Java-AST' 0 SmalltalkAppletContext SmalltalkAppletContext stx:libjava 'Languages-Java-Views-Support' 0 @@ -135,5 +135,4 @@ JavaNativeMethod JavaNativeMethod stx:libjava 'Languages-Java-Classes' 0 JavaUtilities JavaUtilities stx:libjava 'Languages-Java-Utilities' 0 JavaFieldDescriptorWithUnionType JavaFieldDescriptorWithUnionType stx:libjava 'Languages-Java-Support' 0 -Benchmarks::JavaLookup Benchmarks__JavaLookup stx:libjava 'benchmarks-Misc' 0 ToObject2 ToObject2 stx:libjava 'Languages-Java-Experiments-TO' 0 diff -r 1a973b2da424 -r a2e2c13b0ff6 src/bc.mak --- a/src/bc.mak Sun Jan 01 14:47:13 2012 +0000 +++ b/src/bc.mak Sun Jan 01 17:03:10 2012 +0000 @@ -1,7 +1,7 @@ # $Header$ # # DO NOT EDIT -# automagically generated from the projectDefinition: stx_libjava at 2011-12-31 11:24:50.965. +# automagically generated from the projectDefinition: stx_libjava at 2012-01-01 18:01:41.246. # # Warning: once you modify this file, do not rerun # stmkmp or projectDefinition-build again - otherwise, your changes are lost. @@ -88,7 +88,6 @@ # BEGINMAKEDEPEND --- do not remove this line; make depend needs it -$(OUTDIR)Benchmarks__JavaLookup.$(O) Benchmarks__JavaLookup.$(H): Benchmarks__JavaLookup.st $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)Java.$(O) Java.$(H): Java.st $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)JavaAnnotation.$(O) JavaAnnotation.$(H): JavaAnnotation.st $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)JavaAnnotationContainer.$(O) JavaAnnotationContainer.$(H): JavaAnnotationContainer.st $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) @@ -169,7 +168,7 @@ $(OUTDIR)JavaMethodDeclaratorNode.$(O) JavaMethodDeclaratorNode.$(H): JavaMethodDeclaratorNode.st $(INCLUDE_TOP)\stx\libjava\JavaNode.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)JavaMethodDescriptor.$(O) JavaMethodDescriptor.$(H): JavaMethodDescriptor.st $(INCLUDE_TOP)\stx\libjava\JavaDescriptor.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)JavaMethodNode.$(O) JavaMethodNode.$(H): JavaMethodNode.st $(INCLUDE_TOP)\stx\libjava\JavaNode.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) -$(OUTDIR)JavaPetitParser.$(O) JavaPetitParser.$(H): JavaPetitParser.st $(INCLUDE_TOP)\squeak\petitparser\PPCompositeParser.$(H) $(INCLUDE_TOP)\squeak\petitparser\PPDelegateParser.$(H) $(INCLUDE_TOP)\squeak\petitparser\PPParser.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(INCLUDE_TOP)\stx\libbasic\ReadStream.$(H) $(INCLUDE_TOP)\stx\libbasic\PositionableStream.$(H) $(INCLUDE_TOP)\stx\libbasic\PeekableStream.$(H) $(INCLUDE_TOP)\stx\libbasic\Stream.$(H) $(INCLUDE_TOP)\stx\libjava\PPJavaNode.$(H) $(STCHDR) +$(OUTDIR)JavaPetitParser.$(O) JavaPetitParser.$(H): JavaPetitParser.st $(INCLUDE_TOP)\squeak\petitparser\PPCompositeParser.$(H) $(INCLUDE_TOP)\squeak\petitparser\PPDelegateParser.$(H) $(INCLUDE_TOP)\squeak\petitparser\PPParser.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(INCLUDE_TOP)\stx\libjava\PPJavaNode.$(H) $(INCLUDE_TOP)\stx\libbasic\ReadStream.$(H) $(INCLUDE_TOP)\stx\libbasic\PositionableStream.$(H) $(INCLUDE_TOP)\stx\libbasic\PeekableStream.$(H) $(INCLUDE_TOP)\stx\libbasic\Stream.$(H) $(STCHDR) $(OUTDIR)JavaStringRef2.$(O) JavaStringRef2.$(H): JavaStringRef2.st $(INCLUDE_TOP)\stx\libjava\JavaRef2.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)JavaTypeNode.$(O) JavaTypeNode.$(H): JavaTypeNode.st $(INCLUDE_TOP)\stx\libjava\JavaNode.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) $(OUTDIR)JavaUnhandledExceptionError.$(O) JavaUnhandledExceptionError.$(H): JavaUnhandledExceptionError.st $(INCLUDE_TOP)\stx\libjava\JavaError.$(H) $(INCLUDE_TOP)\stx\libbasic\Error.$(H) $(INCLUDE_TOP)\stx\libbasic\Exception.$(H) $(INCLUDE_TOP)\stx\libbasic\GenericException.$(H) $(INCLUDE_TOP)\stx\libbasic\Object.$(H) $(STCHDR) diff -r 1a973b2da424 -r a2e2c13b0ff6 src/extensions.st --- a/src/extensions.st Sun Jan 01 14:47:13 2012 +0000 +++ b/src/extensions.st Sun Jan 01 17:03:10 2012 +0000 @@ -240,6 +240,15 @@ "Created: / 08-04-2011 / 16:12:45 / Marcel Hlopko " ! ! +!Object methodsFor:'testing'! + +isJavaWrapperClass + "return true, if this is a java wrapper class, i.e, java.lang.Integer, java.lang.Boolean etc." + + ^ false + + "Created: / 01-01-2012 / 17:25:52 / Jan Vrany " +! ! !Object methodsFor:'autoboxing support'! javaBox: anObject diff -r 1a973b2da424 -r a2e2c13b0ff6 src/libjava.rc --- a/src/libjava.rc Sun Jan 01 14:47:13 2012 +0000 +++ b/src/libjava.rc Sun Jan 01 17:03:10 2012 +0000 @@ -3,7 +3,7 @@ // automagically generated from the projectDefinition: stx_libjava. // VS_VERSION_INFO VERSIONINFO - FILEVERSION 6,2,1682,1682 + FILEVERSION 6,2,1685,1685 PRODUCTVERSION 6,2,1,1 #if (__BORLANDC__) FILEFLAGSMASK VS_FF_DEBUG | VS_FF_PRERELEASE @@ -20,12 +20,12 @@ BEGIN VALUE "CompanyName", "eXept Software AG\0" VALUE "FileDescription", "Smalltalk/X Class library (LIB)\0" - VALUE "FileVersion", "6.2.1682.1682\0" + VALUE "FileVersion", "6.2.1685.1685\0" VALUE "InternalName", "stx:libjava\0" VALUE "LegalCopyright", "Copyright Claus Gittinger 1988-2011\nCopyright eXept Software AG 1998-2011\nCopyright Jan Vrany, Jan Kurs and Marcel Hlopko\b SWING Research Group, Czech Technical University In Prague\0" VALUE "ProductName", "Smalltalk/X\0" VALUE "ProductVersion", "6.2.1.1\0" - VALUE "ProductDate", "Sat, 31 Dec 2011 10:25:22 GMT\0" + VALUE "ProductDate", "Sun, 01 Jan 2012 17:01:49 GMT\0" END END diff -r 1a973b2da424 -r a2e2c13b0ff6 src/stx_libjava.st --- a/src/stx_libjava.st Sun Jan 01 14:47:13 2012 +0000 +++ b/src/stx_libjava.st Sun Jan 01 17:03:10 2012 +0000 @@ -162,18 +162,18 @@ exclude individual packages in the #excludedFromPrerequisites method." ^ #( - #'squeak:petitparser' "PPParser - superclass of JavaPetitParser::CommentParser " - #'stx:goodies/sunit' "TestSuite - referenced by stx_libjava class>>testSuite " - #'stx:libbasic' "IdentityDictionary - superclass of extended UserPreferences " - #'stx:libbasic2' "Socket - superclass of JavaSocket " - #'stx:libbasic3' "WrappedMethod - extended " + #'squeak:petitparser' "PPCompositeParser - superclass of JavaPetitParser " + #'stx:goodies/sunit' "TestCase - superclass of JavaTestCaseProxy " + #'stx:libbasic' "Class - superclass of JavaClass " + #'stx:libbasic2' "BitArray - superclass of extended BooleanArray " + #'stx:libbasic3' "MessageTracer - referenced by JavaMethod>>setBreakPoint " #'stx:libcomp' "ObjectFileLoader - referenced by JavaVM class>>_Runtime_loadFileInternalI: " #'stx:libhtml' "URL - referenced by JavaEmbeddedFrameView>>setupAppletFrameIn:initializeJava: " #'stx:libtool' "WorkspaceApplication - referenced by JavaEvaluator>>evaluate:in:receiver:notifying:logged:ifFail: " - #'stx:libview' "SimpleView - superclass of JavaView " - #'stx:libview2' "GIFReader - referenced by JavaVM class>>_GifImageDecoder_parseImage: " - #'stx:libwidg' "Scroller - referenced by JavaVM class>>processEvent: " - #'stx:libwidg2' "MenuPanel - referenced by JavaVM class>>processEvent: " + #'stx:libview' "TopView - superclass of JavaTopView " + #'stx:libview2' "Plug - referenced by JavaSourceCodeCache>>findMethodLine:inMethods: " + #'stx:libwidg' "Button - referenced by JavaVM class>>_WButtonPeer_create: " + #'stx:libwidg2' "CheckBox - referenced by JavaVM class>>_WCheckboxPeer_create: " ) ! ! @@ -397,7 +397,7 @@ JavaNativeMethod JavaUtilities JavaFieldDescriptorWithUnionType - #'Benchmarks::JavaLookup' + ToObject2 ) ! @@ -535,6 +535,9 @@ 'ProjectDefinition class' javaSourcePath WrappedMethod descriptor Object javaWrap: + Object isJavaWrapperClass + Object javaUnwrapFrom: + SmallInteger javaUnwrapFrom: ) ! !