对于以下代码:
private double currentTime;
private Queue<ScheduledEvent<S>> diary;
public Simulation() {
diary = new PriorityQueue<ScheduledEvent<S>>;
}
在一个名为的抽象类Simulation<S>中,我得到了以下所有 Eclipse 错误。
Syntax error on tokens, delete these tokensSyntax error, insert ">>" to complete ReferenceType2Syntax error, insert "AssignmentOperator Expression" to complete AssignmentSyntax error, insert ";" to complete BlockStatements
原因是什么?我没有看到任何可能导致这种情况的拼写错误或空作业。