From 7e984e3e01a377e5fe33f565c1846de3c4d98709 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Sun, 30 Nov 2014 14:33:44 +0100 Subject: mds-kbdc: detect resursive inclusion MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- .../process-includes/invalid/_inclusion_circle | 1 + .../process-includes/invalid/_inclusion_rho_1 | 2 + .../process-includes/invalid/_inclusion_rho_2 | 2 + .../process-includes/invalid/_inclusion_rho_3 | 2 + .../process-includes/invalid/_inclusion_rho_4 | 2 + .../process-includes/invalid/inclusion_circle | 22 +++++++++++ .../process-includes/invalid/inclusion_rho | 43 ++++++++++++++++++++++ .../process-includes/invalid/selfinclusion | 15 ++++++++ 8 files changed, 89 insertions(+) create mode 100644 test-files/mds-kbdc/process-includes/invalid/_inclusion_circle create mode 100644 test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_1 create mode 100644 test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2 create mode 100644 test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_3 create mode 100644 test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_4 create mode 100644 test-files/mds-kbdc/process-includes/invalid/inclusion_circle create mode 100644 test-files/mds-kbdc/process-includes/invalid/inclusion_rho create mode 100644 test-files/mds-kbdc/process-includes/invalid/selfinclusion (limited to 'test-files') diff --git a/test-files/mds-kbdc/process-includes/invalid/_inclusion_circle b/test-files/mds-kbdc/process-includes/invalid/_inclusion_circle new file mode 100644 index 0000000..56d1212 --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/_inclusion_circle @@ -0,0 +1 @@ +include "inclusion_circle" diff --git a/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_1 b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_1 new file mode 100644 index 0000000..49647dd --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_1 @@ -0,0 +1,2 @@ +include "_inclusion_rho_2" + diff --git a/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2 b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2 new file mode 100644 index 0000000..b7847a6 --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2 @@ -0,0 +1,2 @@ +include "_inclusion_rho_3" + diff --git a/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_3 b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_3 new file mode 100644 index 0000000..8cdf4df --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_3 @@ -0,0 +1,2 @@ +include "_inclusion_rho_4" + diff --git a/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_4 b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_4 new file mode 100644 index 0000000..49647dd --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_4 @@ -0,0 +1,2 @@ +include "_inclusion_rho_2" + diff --git a/test-files/mds-kbdc/process-includes/invalid/inclusion_circle b/test-files/mds-kbdc/process-includes/invalid/inclusion_circle new file mode 100644 index 0000000..11214e7 --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/inclusion_circle @@ -0,0 +1,22 @@ +include "_inclusion_circle" + +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/_inclusion_circle’ +# (.inner +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/inclusion_circle’ +# (.inner +# (include (@ 1 0-7) ‘"_inclusion_circle"’ +# (.inner nil) +# ) +# ) +# ) +# ) +# ) +# .../test-files/mds-kbdc/process-includes/invalid/inclusion_circle: error: resursive inclusion +# +# .../test-files/mds-kbdc/process-includes/invalid/inclusion_circle:1:0–7: note: included from here +# include "_inclusion_circle" +# ^^^^^^^ +# .../test-files/mds-kbdc/process-includes/invalid/_inclusion_circle:1:0–7: note: included from here +# include "inclusion_circle" +# ^^^^^^^ + diff --git a/test-files/mds-kbdc/process-includes/invalid/inclusion_rho b/test-files/mds-kbdc/process-includes/invalid/inclusion_rho new file mode 100644 index 0000000..43aabc9 --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/inclusion_rho @@ -0,0 +1,43 @@ +include "_inclusion_rho_1" + +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_1’ +# (.inner +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2’ +# (.inner +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_3’ +# (.inner +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_4’ +# (.inner +# (include (@ 1 0-7) ‘.../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2’ +# (.inner +# (include (@ 1 0-7) ‘"_inclusion_rho_3"’ +# (.inner nil) +# ) +# ) +# ) +# ) +# ) +# ) +# ) +# ) +# ) +# ) +# ) +# .../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2: error: resursive inclusion +# +# .../test-files/mds-kbdc/process-includes/invalid/inclusion_rho:1:0–7: note: included from here +# include "_inclusion_rho_1" +# ^^^^^^^ +# .../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_1:1:0–7: note: included from here +# include "_inclusion_rho_2" +# ^^^^^^^ +# .../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_2:1:0–7: note: included from here +# include "_inclusion_rho_3" +# ^^^^^^^ +# .../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_3:1:0–7: note: included from here +# include "_inclusion_rho_4" +# ^^^^^^^ +# .../test-files/mds-kbdc/process-includes/invalid/_inclusion_rho_4:1:0–7: note: included from here +# include "_inclusion_rho_2" +# ^^^^^^^ + diff --git a/test-files/mds-kbdc/process-includes/invalid/selfinclusion b/test-files/mds-kbdc/process-includes/invalid/selfinclusion new file mode 100644 index 0000000..5207dbd --- /dev/null +++ b/test-files/mds-kbdc/process-includes/invalid/selfinclusion @@ -0,0 +1,15 @@ +include "selfinclusion" + +# (include (@ 1 0-7) ‘.../mds/test-files/mds-kbdc/process-includes/invalid/selfinclusion’ +# (.inner +# (include (@ 1 0-7) ‘"selfinclusion"’ +# (.inner nil) +# ) +# ) +# ) +# .../test-files/mds-kbdc/process-includes/invalid/selfinclusion: error: resursive inclusion +# +# .../test-files/mds-kbdc/process-includes/invalid/selfinclusion:1:0–7: note: included from here +# include "selfinclusion" +# ^^^^^^^ + -- cgit v1.2.3-70-g09d2