From e36994f54b9f2a580b87e6d0824fc36618551fcf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Wed, 22 Jul 2009 18:48:42 +0200 Subject: [PATCH] astyle formatting --- test/testother.cpp | 72 +++++++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 36 deletions(-) diff --git a/test/testother.cpp b/test/testother.cpp index 715a36ac8..dee0f6783 100644 --- a/test/testother.cpp +++ b/test/testother.cpp @@ -450,61 +450,61 @@ private: { // errors.. checkNullPointer("void foo(struct ABC *abc)\n" - "{\n" - " int *a = abc->a;\n" - " if (!abc)\n" - " ;\n" - "}\n"); + "{\n" + " int *a = abc->a;\n" + " if (!abc)\n" + " ;\n" + "}\n"); ASSERT_EQUALS("[test.cpp:3]: (error) Possible null pointer dereference\n", errout.str()); // ok dereferencing in a condition checkNullPointer("void foo(struct ABC *abc)\n" - "{\n" - " if (abc && abc->a);\n" - " if (!abc)\n" - " ;\n" - "}\n"); + "{\n" + " if (abc && abc->a);\n" + " if (!abc)\n" + " ;\n" + "}\n"); ASSERT_EQUALS("", errout.str()); // ok to use a linked list.. checkNullPointer("void foo(struct ABC *abc)\n" - "{\n" - " abc = abc->next;\n" - " if (!abc)\n" - " ;\n" - "}\n"); + "{\n" + " abc = abc->next;\n" + " if (!abc)\n" + " ;\n" + "}\n"); ASSERT_EQUALS("", errout.str()); // reassign struct.. checkNullPointer("void foo(struct ABC *abc)\n" - "{\n" - " a = abc->a;\n" - " abc = abc->next;\n" - " if (!abc)\n" - " ;\n" - "}\n"); + "{\n" + " a = abc->a;\n" + " abc = abc->next;\n" + " if (!abc)\n" + " ;\n" + "}\n"); ASSERT_EQUALS("", errout.str()); checkNullPointer("void foo(struct ABC *abc)\n" - "{\n" - " a = abc->a;\n" - " f(&abc);\n" - " if (!abc)\n" - " ;\n" - "}\n"); + "{\n" + " a = abc->a;\n" + " f(&abc);\n" + " if (!abc)\n" + " ;\n" + "}\n"); ASSERT_EQUALS("", errout.str()); // goto.. checkNullPointer("void foo(struct ABC *abc)\n" - "{\n" - " if (!abc)\n" - " goto out;" - " a = abc->a;\n" - " return;\n" - "out:\n" - " if (!abc)\n" - " ;\n" - "}\n"); + "{\n" + " if (!abc)\n" + " goto out;" + " a = abc->a;\n" + " return;\n" + "out:\n" + " if (!abc)\n" + " ;\n" + "}\n"); ASSERT_EQUALS("", errout.str()); }