Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(179)

Unified Diff: dart/language/grammar/TestGrammar.java

Issue 10917035: Remove language directory. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « dart/language/grammar/PRESUBMIT.py ('k') | dart/language/grammar/antlrworks.jar » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/language/grammar/TestGrammar.java
diff --git a/dart/language/grammar/TestGrammar.java b/dart/language/grammar/TestGrammar.java
deleted file mode 100644
index bf1702037ff8b3bae59336e313080343a880d546..0000000000000000000000000000000000000000
--- a/dart/language/grammar/TestGrammar.java
+++ /dev/null
@@ -1,39 +0,0 @@
-// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-package com.google.dart.antlr;
-
-import org.antlr.runtime.ANTLRFileStream;
-import org.antlr.runtime.CharStream;
-import org.antlr.runtime.CommonTokenStream;
-
-/**
- * Test rig for testing the Dart grammar.
- */
-public class TestGrammar {
- public static void main(String... arguments) throws Exception {
- boolean hasErrors = false;
- if (arguments.length == 0) {
- throw new AssertionError("No files given on command line");
- }
- for (String argument : arguments) {
- CharStream input = new ANTLRFileStream(argument, "UTF8");
- DartLexer lexer = new DartLexer(input);
- CommonTokenStream tokens = new CommonTokenStream(lexer);
- DartParser parser = new DartParser(tokens);
- if (argument.endsWith(".lib")) {
- parser.libraryUnit();
- } else if (argument.endsWith(".dart")) {
- parser.compilationUnit();
- } else {
- throw new AssertionError("Unknown file type: " + argument);
- }
- hasErrors |= lexer.hasErrors;
- hasErrors |= parser.hasErrors;
- }
- if (hasErrors) {
- throw new AssertionError("Parse errors");
- }
- }
-}
« no previous file with comments | « dart/language/grammar/PRESUBMIT.py ('k') | dart/language/grammar/antlrworks.jar » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698