From c04e04146e6a72db58c9f5c4a669e72b1bb89357 Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen Date: Fri, 13 Nov 2015 21:19:30 +0200 Subject: [PATCH] Use two inputs for a generator to test edge cases. --- test cases/common/59 object generator/meson.build | 2 +- test cases/common/59 object generator/prog.c | 5 +++-- test cases/common/59 object generator/source.c | 2 +- test cases/common/59 object generator/source2.c | 3 +++ 4 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 test cases/common/59 object generator/source2.c diff --git a/test cases/common/59 object generator/meson.build b/test cases/common/59 object generator/meson.build index 761ef776e..fc31ed600 100644 --- a/test cases/common/59 object generator/meson.build +++ b/test cases/common/59 object generator/meson.build @@ -18,7 +18,7 @@ gen = generator(python, output : outputname, arguments : [comp, cc, '@INPUT@', '@OUTPUT@']) -generated = gen.process('source.c') +generated = gen.process(['source.c', 'source2.c']) e = executable('prog', 'prog.c', generated) diff --git a/test cases/common/59 object generator/prog.c b/test cases/common/59 object generator/prog.c index ce5c1cb16..ba793f297 100644 --- a/test cases/common/59 object generator/prog.c +++ b/test cases/common/59 object generator/prog.c @@ -1,5 +1,6 @@ -int func_in_obj(); +int func1_in_obj(); +int func2_in_obj(); int main(int argc, char **argv) { - return func_in_obj(); + return func1_in_obj() + func2_in_obj(); } diff --git a/test cases/common/59 object generator/source.c b/test cases/common/59 object generator/source.c index a6920d175..7779b332c 100644 --- a/test cases/common/59 object generator/source.c +++ b/test cases/common/59 object generator/source.c @@ -1,3 +1,3 @@ -int func_in_obj() { +int func1_in_obj() { return 0; } diff --git a/test cases/common/59 object generator/source2.c b/test cases/common/59 object generator/source2.c new file mode 100644 index 000000000..29aad40f3 --- /dev/null +++ b/test cases/common/59 object generator/source2.c @@ -0,0 +1,3 @@ +int func2_in_obj() { + return 0; +}