--- a/src/JavaLookup.st Mon Apr 02 17:43:24 2012 +0000
+++ b/src/JavaLookup.st Tue Apr 03 12:02:05 2012 +0000
@@ -636,6 +636,7 @@
cls := arg class.
candidates := candidates select:[:m|
+self breakPoint:#mh.
self type: cls matches: (m descriptor parameters at: index) javaClass
].
].
@@ -650,28 +651,23 @@
self halt: 'Unfinished - ambiguous'
"Created: / 03-01-2012 / 21:40:23 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+ "Modified: / 03-04-2012 / 13:59:13 / Marcel Hlopko <hlopkmar@fel.cvut.cz>"
!
-type: actual matches: formal
+type: actual matches: formal
"Return true, if actual (parameter) type matches given formal (parameter) type"
- formal isJavaPrimitiveType ifTrue:[
- ^ actual == formal.
+ formal isJavaPrimitiveType ifTrue: [ ^ actual == formal. ].
+ actual isJavaPrimitiveType ifTrue: [
+ ^ formal isJavaWrapperClass and: [ formal javaWrapperClass == actual. ]
].
-
- actual isJavaPrimitiveType ifTrue:[
- ^ formal isJavaWrapperClass and:[
- formal javaWrapperClass == actual.
- ]
+ (actual includesBehavior: String "care about multi-byte strings") ifTrue: [
+ ^ formal name == #'java/lang/String'
].
-
- (actual includesBehavior: String)"care about multi-byte strings" ifTrue:[
- ^formal name == #'java/lang/String'
- ].
-
- ^JavaVM canCast: actual to: formal
+ ^ JavaVM canCast: actual to: formal
"Created: / 03-01-2012 / 22:36:19 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+ "Modified: / 03-04-2012 / 13:59:28 / Marcel Hlopko <hlopkmar@fel.cvut.cz>"
! !
!JavaLookup::Smalltalk2Java methodsFor:'utilities (old)'!