rm deadcode

This commit is contained in:
parrt 2017-03-17 12:07:01 -07:00
parent 251d27493e
commit 553742e149
1 changed files with 0 additions and 25 deletions

View File

@ -7,10 +7,8 @@ import org.antlr.v4.runtime.CommonTokenStream;
import org.antlr.v4.runtime.Lexer;
import org.antlr.v4.test.runtime.java.api.JavaLexer;
import java.io.File;
import java.net.URL;
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
@ -146,29 +144,6 @@ public class TimeLexerSpeed { // don't call it Test else it'll run during "mvn t
return avg(times);
}
public static List<String> getFilenames(File f, String inputFilePattern) throws Exception {
List<String> files = new ArrayList<String>();
getFilenames_(f, files, inputFilePattern);
return files;
}
public static void getFilenames_(File f, List<String> files, String inputFilePattern) throws Exception {
// If this is a directory, walk each file/dir in that directory
if (f.isDirectory()) {
String flist[] = f.list();
for(int i=0; i < flist.length; i++) {
getFilenames_(new File(f, flist[i]), files, inputFilePattern);
}
}
// otherwise, if this is an input file, parse it!
else if ( inputFilePattern==null || f.getName().matches(inputFilePattern) &&
f.getName().indexOf('-')<0 ) // don't allow preprocessor files like ByteBufferAs-X-Buffer.java
{
files.add(f.getAbsolutePath());
}
}
public double avg(long[] values) {
double sum = 0.0;
for (Long v : values) {