diff --git a/build.gradle b/build.gradle index 8bbe144e..9c7fec1d 100644 --- a/build.gradle +++ b/build.gradle @@ -15,7 +15,7 @@ repositories { dependencies { testImplementation "junit:junit:4.13.2" implementation "org.json:json:20231013" - implementation "com.github.javaparser:javaparser-core:3.12.0" + implementation "com.github.javaparser:javaparser-core:3.25.7" implementation "com.google.guava:guava:32.1.3-jre" testImplementation "com.google.truth:truth:1.1.5" testImplementation "com.google.truth.extensions:truth-java8-extension:1.1.5" diff --git a/src/main/java/analyzer/exercises/Exercise.java b/src/main/java/analyzer/exercises/Exercise.java index 70a943f6..08f9fef0 100644 --- a/src/main/java/analyzer/exercises/Exercise.java +++ b/src/main/java/analyzer/exercises/Exercise.java @@ -43,7 +43,7 @@ private Exercise(File solutionFile, FileWriter analysisFileWriter, FileWriter ta this.tagsFileWriter = tagsFileWriter; try { - this.compilationUnit = JavaParser.parse(solutionFile); + this.compilationUnit = new JavaParser().parse(solutionFile).getResult().get(); } catch (ParseProblemException e) { addComment(GeneralComment.FAILED_PARSE); } catch (FileNotFoundException e) {