From 7c6c9251c23e4923ae4353a34aa7d83b5a5840d1 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Mon, 8 Dec 2014 17:32:01 +0100 Subject: mds-kbdc: compile-layout. bug fixes, test-cases and mark all untested error reports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- .../mds-kbdc/compile-layout/invalid/bad_name_suffix | 17 +++++++++++++++++ .../compile-layout/invalid/function-undefined_function | 8 ++++++++ .../invalid/function-undefined_function-call | 5 +++++ .../compile-layout/invalid/function_calls_itself | 4 ++++ test-files/mds-kbdc/compile-layout/invalid/loopy_error | 2 +- .../compile-layout/invalid/macro-undefined_function | 4 ++++ .../compile-layout/invalid/macro-undefined_macro | 4 ++++ .../compile-layout/invalid/macro-undefined_macro-call | 5 +++++ .../mds-kbdc/compile-layout/invalid/macro_calls_itself | 4 ++++ .../mds-kbdc/compile-layout/invalid/not_a_variable | 12 ++++++++++++ .../compile-layout/invalid/redefine_builtin_function | 3 +++ .../mds-kbdc/compile-layout/invalid/redefine_function | 5 +++++ .../mds-kbdc/compile-layout/invalid/redefine_macro | 5 +++++ 13 files changed, 77 insertions(+), 1 deletion(-) create mode 100644 test-files/mds-kbdc/compile-layout/invalid/bad_name_suffix create mode 100644 test-files/mds-kbdc/compile-layout/invalid/function-undefined_function create mode 100644 test-files/mds-kbdc/compile-layout/invalid/function-undefined_function-call create mode 100644 test-files/mds-kbdc/compile-layout/invalid/function_calls_itself create mode 100644 test-files/mds-kbdc/compile-layout/invalid/macro-undefined_function create mode 100644 test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro create mode 100644 test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro-call create mode 100644 test-files/mds-kbdc/compile-layout/invalid/macro_calls_itself create mode 100644 test-files/mds-kbdc/compile-layout/invalid/not_a_variable create mode 100644 test-files/mds-kbdc/compile-layout/invalid/redefine_builtin_function create mode 100644 test-files/mds-kbdc/compile-layout/invalid/redefine_function create mode 100644 test-files/mds-kbdc/compile-layout/invalid/redefine_macro (limited to 'test-files/mds-kbdc/compile-layout') diff --git a/test-files/mds-kbdc/compile-layout/invalid/bad_name_suffix b/test-files/mds-kbdc/compile-layout/invalid/bad_name_suffix new file mode 100644 index 0000000..594b4f7 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/bad_name_suffix @@ -0,0 +1,17 @@ +function n +end function +macro n/ +end macro +function n/01 +end function +macro n/a +end macro +function n/1 # this one is good +end function +macro n/9 # this one is good +end macro +function n/0 # this one is good +end function +macro n/10 # this one is good +end macro + diff --git a/test-files/mds-kbdc/compile-layout/invalid/function-undefined_function b/test-files/mds-kbdc/compile-layout/invalid/function-undefined_function new file mode 100644 index 0000000..9712868 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/function-undefined_function @@ -0,0 +1,8 @@ +function f/0 + for \f(1) to \f(1) as \1 + if \f(1) + \f(1) + end if + end for +end function + diff --git a/test-files/mds-kbdc/compile-layout/invalid/function-undefined_function-call b/test-files/mds-kbdc/compile-layout/invalid/function-undefined_function-call new file mode 100644 index 0000000..c0f195b --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/function-undefined_function-call @@ -0,0 +1,5 @@ +function f/0 + \f(1) +end function +\f() + diff --git a/test-files/mds-kbdc/compile-layout/invalid/function_calls_itself b/test-files/mds-kbdc/compile-layout/invalid/function_calls_itself new file mode 100644 index 0000000..1201ad5 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/function_calls_itself @@ -0,0 +1,4 @@ +function f/0 + \f() +end function + diff --git a/test-files/mds-kbdc/compile-layout/invalid/loopy_error b/test-files/mds-kbdc/compile-layout/invalid/loopy_error index 44fe098..c68fbe4 100644 --- a/test-files/mds-kbdc/compile-layout/invalid/loopy_error +++ b/test-files/mds-kbdc/compile-layout/invalid/loopy_error @@ -1,4 +1,4 @@ for 1 to 3 as \1 - : \1 + : 0 end for diff --git a/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_function b/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_function new file mode 100644 index 0000000..ca3f975 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_function @@ -0,0 +1,4 @@ +macro m/0 + <\f()> : \f() +end macro + diff --git a/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro b/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro new file mode 100644 index 0000000..3654b50 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro @@ -0,0 +1,4 @@ +macro m/0 + m(1) +end macro + diff --git a/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro-call b/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro-call new file mode 100644 index 0000000..69f2f8e --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/macro-undefined_macro-call @@ -0,0 +1,5 @@ +macro m/0 + m(1) +end macro +m() + diff --git a/test-files/mds-kbdc/compile-layout/invalid/macro_calls_itself b/test-files/mds-kbdc/compile-layout/invalid/macro_calls_itself new file mode 100644 index 0000000..2f4a5dd --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/macro_calls_itself @@ -0,0 +1,4 @@ +macro m/0 + m() +end macro + diff --git a/test-files/mds-kbdc/compile-layout/invalid/not_a_variable b/test-files/mds-kbdc/compile-layout/invalid/not_a_variable new file mode 100644 index 0000000..cc189ea --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/not_a_variable @@ -0,0 +1,12 @@ +let 1 : 1 +let \. : 1 +let \0 : 1 +let \0. : 1 +let \1.. : 1 +let \1 : 1 # this one is good +let \1. : 1 # this one is good +let \9 : 1 # this one is good +let \a : 1 +let \f() : 1 +let a : 1 + diff --git a/test-files/mds-kbdc/compile-layout/invalid/redefine_builtin_function b/test-files/mds-kbdc/compile-layout/invalid/redefine_builtin_function new file mode 100644 index 0000000..2d9a769 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/redefine_builtin_function @@ -0,0 +1,3 @@ +function set/3 +end function + diff --git a/test-files/mds-kbdc/compile-layout/invalid/redefine_function b/test-files/mds-kbdc/compile-layout/invalid/redefine_function new file mode 100644 index 0000000..7147a02 --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/redefine_function @@ -0,0 +1,5 @@ +function f/0 +end function +function f/0 +end function + diff --git a/test-files/mds-kbdc/compile-layout/invalid/redefine_macro b/test-files/mds-kbdc/compile-layout/invalid/redefine_macro new file mode 100644 index 0000000..03fe15a --- /dev/null +++ b/test-files/mds-kbdc/compile-layout/invalid/redefine_macro @@ -0,0 +1,5 @@ +macro m/0 +end macro +macro m/0 +end macro + -- cgit v1.2.3-70-g09d2