From 5dbb7ecd0f4106939d2e52c5027dcb1d0fc8db9e Mon Sep 17 00:00:00 2001 From: Christian Fritz Date: Tue, 12 Jan 2016 19:36:41 -0800 Subject: [PATCH] Updated indentation regexes for new language-mode logic This is for the following atom/atom PR: https://github.com/atom/atom/pull/10384 There is a cyclic dependency between these two (an artifact caused by the separation of the two repos). Hence, both test suits (for this package as well as for atom/atom, will fail until both are merged. --- settings/language-c.cson | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/settings/language-c.cson b/settings/language-c.cson index 17d33e4..5bf364a 100644 --- a/settings/language-c.cson +++ b/settings/language-c.cson @@ -2,18 +2,20 @@ 'editor': 'commentStart': '// ' 'increaseIndentPattern': '(?x) - ^ .* \\{ [^}"\']* $ - |^ .* \\( [^\\)"\']* $ + [\\{\\(] |^ \\s* (public|private|protected): \\s* $ |^ \\s* @(public|private|protected) \\s* $ |^ \\s* \\{ \\} $ ' - 'decreaseIndentPattern': '(?x) + 'decreaseThisIndentPattern': '(?x) ^ \\s* (\\s* /[*] .* [*]/ \\s*)* \\} |^ \\s* (\\s* /[*] .* [*]/ \\s*)* \\) |^ \\s* (public|private|protected): \\s* $ |^ \\s* @(public|private|protected) \\s* $ ' + 'decreaseIndentPattern': '(?x) + [\\}\\)] + ' '.source.c, .source.cpp': 'editor': 'foldEndPattern': '(?