Vector<Integer> kann nicht geparst werden #224

Closed
opened 2017-10-30 17:38:13 +00:00 by pl · 1 comment
Owner

import java.util.Vector;

class Matrix extends Vector<Vector> {

methode(Matrix m) {
Vector<Vector> i;
methode(i);
}
}

liefert folgenden Fehler

de.dhbwstuttgart.exceptions.TypeinferenceException: Der Typ Vector ist nicht vorhanden
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convertTypeName(TypeGenerator.java:121)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convertTypeName(TypeGenerator.java:112)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convert(TypeGenerator.java:108)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convert(TypeGenerator.java:138)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convertTypeName(TypeGenerator.java:127)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convert(SyntaxTreeGenerator.java:279)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convertNormal(SyntaxTreeGenerator.java:223)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convertClass(SyntaxTreeGenerator.java:196)
at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convert(SyntaxTreeGenerator.java:127)
at de.dhbwstuttgart.core.JavaTXCompiler.parse(JavaTXCompiler.java:99)
at de.dhbwstuttgart.core.JavaTXCompiler.(JavaTXCompiler.java:42)
at de.dhbwstuttgart.core.JavaTXCompiler.(JavaTXCompiler.java:36)
at typeinference.JavaTXCompilerTest.test(JavaTXCompilerTest.java:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.junit.internal.runners.TestMethodRunner.executeMethodBody(TestMethodRunner.java:99)
at org.junit.internal.runners.TestMethodRunner.runUnprotected(TestMethodRunner.java:81)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75)
at org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45)
at org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71)
at org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35)
at org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42)
at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34)
at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:678)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192

import java.util.Vector; class Matrix extends Vector<Vector<Integer>> { methode(Matrix m) { Vector<Vector<Integer>> i; methode(i); } } liefert folgenden Fehler de.dhbwstuttgart.exceptions.TypeinferenceException: Der Typ Vector<Integer> ist nicht vorhanden at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convertTypeName(TypeGenerator.java:121) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convertTypeName(TypeGenerator.java:112) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convert(TypeGenerator.java:108) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convert(TypeGenerator.java:138) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.TypeGenerator.convertTypeName(TypeGenerator.java:127) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convert(SyntaxTreeGenerator.java:279) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convertNormal(SyntaxTreeGenerator.java:223) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convertClass(SyntaxTreeGenerator.java:196) at de.dhbwstuttgart.parser.SyntaxTreeGenerator.SyntaxTreeGenerator.convert(SyntaxTreeGenerator.java:127) at de.dhbwstuttgart.core.JavaTXCompiler.parse(JavaTXCompiler.java:99) at de.dhbwstuttgart.core.JavaTXCompiler.<init>(JavaTXCompiler.java:42) at de.dhbwstuttgart.core.JavaTXCompiler.<init>(JavaTXCompiler.java:36) at typeinference.JavaTXCompilerTest.test(JavaTXCompilerTest.java:48) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.junit.internal.runners.TestMethodRunner.executeMethodBody(TestMethodRunner.java:99) at org.junit.internal.runners.TestMethodRunner.runUnprotected(TestMethodRunner.java:81) at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34) at org.junit.internal.runners.TestMethodRunner.runMethod(TestMethodRunner.java:75) at org.junit.internal.runners.TestMethodRunner.run(TestMethodRunner.java:45) at org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(TestClassMethodsRunner.java:71) at org.junit.internal.runners.TestClassMethodsRunner.run(TestClassMethodsRunner.java:35) at org.junit.internal.runners.TestClassRunner$1.runUnprotected(TestClassRunner.java:42) at org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:34) at org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:678) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192
Owner

Fixed

commit d2fa9e00f8

Fixed commit d2fa9e00f878e289bf5edb43e811a7a15d3a0618
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: JavaTX/JavaCompilerCore#224
No description provided.