From 9f2447ce94550fae406d5755464526f6e5f4de37 Mon Sep 17 00:00:00 2001 From: emma Date: Mon, 15 Jul 2024 13:38:26 -0600 Subject: [PATCH] STYLE: code block indentation edits and example --- STYLE | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/STYLE b/STYLE index 4344991..23cd0c5 100644 --- a/STYLE +++ b/STYLE @@ -21,8 +21,16 @@ return io; -3. Cases in switch statements and matches in match statements should be indented - one level +3. Each block of code should be indented once more than the keyword which + initiated the block: + + switch (c) { + case 'e': mode |= EQUAL; break; + case 'g': mode |= GREATER; break; + case 'l': mode |= LESS; break; + default: return usage(s); + } + 4. In C, spaces should be placed in control flow statements after the keyword and before the opening brace: