Skip to content

Commit a3a293f

Browse files
committed
housekeeping
1 parent a800d4c commit a3a293f

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/fortran/ofp/XMLPrinterBase.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -696,9 +696,9 @@ protected void printTokens(Token... tokens) {
696696
*/
697697
protected void insertTokens(Element context, int tokenType, String tokenContextName, String tokenTextAttributeName)
698698
throws IOException {
699-
// System.err.println("all tokens: " + new TokensList(new File(filename)));
699+
// LOG.log(Level.INFO, "all tokens: {0}", new TokensList(new File(filename)));
700700
TokensList tokens = new TokensList(new File(filename), tokenType);
701-
// System.err.println("found tokens: " + tokens);
701+
// LOG.log(Level.INFO, "found tokens of type={0}: {1}", new Object[]{tokenType, tokens});
702702
insertTokens(context, tokens, tokenContextName, tokenTextAttributeName);
703703
}
704704

src/fortran/ofp/parser/java/TokensList.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,15 @@
33
import java.io.File;
44
import java.io.IOException;
55
import java.util.ArrayList;
6+
import java.util.logging.Level;
7+
import java.util.logging.Logger;
68

79
import org.antlr.runtime.Token;
810

911
public class TokensList extends ArrayList<Token> {
1012

13+
private static final Logger LOG = Logger.getLogger(TokensList.class.getName());
14+
1115
private static final long serialVersionUID = -8037754729217056476L;
1216

1317
public TokensList(File file) throws IOException {
@@ -30,6 +34,7 @@ public void addAll(File file, Integer onlyOfType) throws IOException {
3034
while (token.getType() != FortranAlternateLexer.EOF) {
3135
if (onlyOfType == null || token.getType() == ((int) onlyOfType))
3236
add(token);
37+
// else LOG.log(Level.INFO, "skipping token of type {0}", token.getType());
3338
token = lexer.nextToken();
3439
}
3540
}

0 commit comments

Comments
 (0)