From c9db5499e9daddb2e0715396108ed00a1cf32bc0 Mon Sep 17 00:00:00 2001 From: Max Brunsfeld Date: Fri, 18 Dec 2015 13:46:24 -0800 Subject: [PATCH] Remove uninteresting corpus entries --- spec/fixtures/corpus/arithmetic/main.txt | 20 -------- spec/fixtures/corpus/c/declarations.txt | 25 ---------- spec/fixtures/corpus/cpp/statements.txt | 16 ------- spec/fixtures/corpus/golang/declarations.txt | 26 +++------- spec/fixtures/corpus/javascript/literals.txt | 29 ++---------- spec/fixtures/corpus/json/main.txt | 50 -------------------- 6 files changed, 11 insertions(+), 155 deletions(-) diff --git a/spec/fixtures/corpus/arithmetic/main.txt b/spec/fixtures/corpus/arithmetic/main.txt index 09f01c4e..08bca8d2 100644 --- a/spec/fixtures/corpus/arithmetic/main.txt +++ b/spec/fixtures/corpus/arithmetic/main.txt @@ -1,23 +1,3 @@ -==================== -numbers -=================== - -5 - ---- - -(program (number)) - -=================== -variables -=================== - -x - ---- - -(program (variable)) - ==================================== variables with greek letters ==================================== diff --git a/spec/fixtures/corpus/c/declarations.txt b/spec/fixtures/corpus/c/declarations.txt index 123e9818..3ca7e7a8 100644 --- a/spec/fixtures/corpus/c/declarations.txt +++ b/spec/fixtures/corpus/c/declarations.txt @@ -1,28 +1,3 @@ -========================================== -simple declarations -========================================== - -int x; - ---- - -(translation_unit - (declaration (identifier) (identifier))) - -========================================== -simple functions -========================================== - -int main() { -} - ---- - -(translation_unit (function_definition - (identifier) - (function_declarator (identifier)) - (compound_statement))) - ========================================== ambiguous declarations ========================================== diff --git a/spec/fixtures/corpus/cpp/statements.txt b/spec/fixtures/corpus/cpp/statements.txt index db4be513..5e545a41 100644 --- a/spec/fixtures/corpus/cpp/statements.txt +++ b/spec/fixtures/corpus/cpp/statements.txt @@ -1,19 +1,3 @@ -================================================== -simple functions cpp -================================================== - -int main() { - x; -} - ---- - -(translation_unit (function_definition - (type_specifier (identifier)) - (declarator (direct_declarator (direct_declarator (identifier)))) - (function_body (compound_statement - (expression_statement (identifier)))))) - ================================================== function calls ================================================== diff --git a/spec/fixtures/corpus/golang/declarations.txt b/spec/fixtures/corpus/golang/declarations.txt index f3eca94d..5a2dbd7d 100644 --- a/spec/fixtures/corpus/golang/declarations.txt +++ b/spec/fixtures/corpus/golang/declarations.txt @@ -4,6 +4,7 @@ simple declarations package trivial +var X struct { Y int64 } type x int64 var y = "" func z() {} @@ -11,26 +12,11 @@ func z() {} --- (program - (package_directive (package_name)) - (type_declaration (type_name) (type_name)) - (var_declaration (var_name) (string)) - (func_declaration (var_name) (block_statement))) - -========================================== -var declarations -========================================== - -package trivial - -var X struct { Y int64 } -var Z = "" - ---- - -(program - (package_directive (package_name)) - (var_declaration (var_name) (struct_type (var_name) (type_name))) - (var_declaration (var_name) (string))) + (package_directive (package_name)) + (var_declaration (var_name) (struct_type (var_name) (type_name))) + (type_declaration (type_name) (type_name)) + (var_declaration (var_name) (string)) + (func_declaration (var_name) (block_statement))) ========================================== comments diff --git a/spec/fixtures/corpus/javascript/literals.txt b/spec/fixtures/corpus/javascript/literals.txt index b027d092..0f4b9452 100644 --- a/spec/fixtures/corpus/javascript/literals.txt +++ b/spec/fixtures/corpus/javascript/literals.txt @@ -1,36 +1,17 @@ ========================================== -regexes +primitives ========================================== theFunction(/regex1/, /regex2/g); - ---- - -(program (expression_statement - (function_call (identifier) (arguments (regex) (regex))))) - -========================================== -numbers -========================================== - theFunction(100.0, 200); - ---- - -(program (expression_statement - (function_call (identifier) (arguments (number) (number))))) - -========================================== -strings -========================================== - theFunction('', "", 'single-quoted-string', "double-quoted-string"); --- -(program (expression_statement - (function_call (identifier) - (arguments (string) (string) (string) (string))))) +(program + (expression_statement (function_call (identifier) (arguments (regex) (regex)))) + (expression_statement (function_call (identifier) (arguments (number) (number)))) + (expression_statement (function_call (identifier) (arguments (string) (string) (string) (string))))) ========================================== function expressions diff --git a/spec/fixtures/corpus/json/main.txt b/spec/fixtures/corpus/json/main.txt index 3e4ed801..80d2c042 100644 --- a/spec/fixtures/corpus/json/main.txt +++ b/spec/fixtures/corpus/json/main.txt @@ -1,43 +1,3 @@ -====================================== -strings with escaped quotes -====================================== - -"ok\"" - ---- - -(string) - -====================================== -strings with other escaped characters -====================================== - -"ok\n\r\n\\ok" - ---- - -(string) - -============================= -floating point numbers -============================= - -3.14 - ---- - -(number) - -=================== -empty arrays -=================== - -[] - ---- - -(array) - =================== arrays =================== @@ -59,16 +19,6 @@ arrays (false) (object (string) (string))) -==================== -empty objects -==================== - -{} - ---- - -(object) - =================== long objects ===================