forked from JavaTX/JavaCompilerCore
Merge branch 'bytecode2' of ssh://gohorb.ba-horb.de/bahome/projekt/git/JavaCompilerCore into bytecode2
Conflicts: test/bytecode/javFiles/Lambda.jav
This commit is contained in:
commit
6bdd347298
@ -119,7 +119,7 @@ public class Signature {
|
||||
if(!ret.equals("V")) {
|
||||
// TODO TypeToSignature nochmal kontrollieren und schauen ob man dort wirklich
|
||||
// T... braucht und L ...
|
||||
if(ret.contains("$") && !ret.contains("$$")) {
|
||||
if(ret.contains("$") && !ret.contains("$$") && !ret.contains("<")) {
|
||||
if(genericsAndBounds.containsKey(ret)) {
|
||||
genericsAndBoundsMethod.put(ret.substring(1), genericsAndBounds.get(ret.substring(1)));
|
||||
}else {
|
||||
@ -233,6 +233,7 @@ public class Signature {
|
||||
if(p instanceof WildcardType) {
|
||||
if(((WildcardType) p).getInnerType() instanceof GenericRefType) {
|
||||
String name = new TypeToSignature().visit((GenericRefType)((WildcardType) p).getInnerType());
|
||||
System.out.println("NAME WC = " + name);
|
||||
if(!genericsAndBoundsMethod.containsKey(name) && !genericsAndBounds.containsKey(name)) {
|
||||
sw.visitFormalTypeParameter(name);
|
||||
sw.visitClassBound().visitClassType(Type.getInternalName(Object.class));
|
||||
|
@ -34,7 +34,7 @@ public class TypeToSignature implements TypeVisitor<String> {
|
||||
// params += "L"+param.toString().replace(".", "/");
|
||||
// }
|
||||
params += param.acceptTV(new TypeToSignature());
|
||||
if(param instanceof TypePlaceholder)
|
||||
if(!(param instanceof RefType))
|
||||
params += ";";
|
||||
// if(it.hasNext())params += ";";
|
||||
}
|
||||
|
@ -42,7 +42,7 @@ public class GenericsResolverSameName implements GenericsResolver, TypeVisitor<R
|
||||
|
||||
@Override
|
||||
public RefTypeOrTPHOrWildcardOrGeneric visit(ExtendsWildcardType extendsWildcardType) {
|
||||
return new SuperWildcardType(extendsWildcardType.getInnerType().acceptTV(this), extendsWildcardType.getOffset());
|
||||
return new ExtendsWildcardType(extendsWildcardType.getInnerType().acceptTV(this), extendsWildcardType.getOffset());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -7,5 +7,4 @@ public class Lambda {
|
||||
return x;
|
||||
};
|
||||
return lam1;
|
||||
}
|
||||
}
|
||||
|
@ -10,11 +10,11 @@ class Merge {
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
|
||||
sort(in){
|
||||
var firstHalf = in.subList(1,2);
|
||||
var secondHalf = in.subList(1,2);
|
||||
return merge(sort(firstHalf), sort(secondHalf));
|
||||
}
|
||||
*/
|
||||
|
||||
}
|
@ -1,29 +1,20 @@
|
||||
import java.lang.String;
|
||||
import java.lang.Integer;
|
||||
import java.lang.Double;
|
||||
import java.lang.String;
|
||||
|
||||
|
||||
<<<<<<< HEAD
|
||||
|
||||
public class OL {
|
||||
|
||||
m(x) { return x + x; }
|
||||
=======
|
||||
class OL {
|
||||
|
||||
m(x) { return x + x; }
|
||||
>>>>>>> 3fedbcc4a0e015ec8f5f6ccb77081f888135c850
|
||||
|
||||
}
|
||||
|
||||
|
||||
<<<<<<< HEAD
|
||||
public class OLMain {
|
||||
=======
|
||||
class OLMain {
|
||||
>>>>>>> 3fedbcc4a0e015ec8f5f6ccb77081f888135c850
|
||||
|
||||
main(java.lang.Integer x) {
|
||||
public class OLMain {
|
||||
|
||||
main(x) {
|
||||
var ol;
|
||||
ol = new OL();
|
||||
return ol.m(x);
|
||||
|
Loading…
Reference in New Issue
Block a user