Daniel Carvalho has uploaded this change for review. (
https://gem5-review.googlesource.com/c/public/gem5/+/43325 )
Change subject: util: Add verifier for opening braces of structs
......................................................................
util: Add verifier for opening braces of structs
Make sure that opening braces of structs are not declared
in the same line of the struct name.
This does not work for multi-line structs.
Change-Id: Ie9d5ccc8f7252ad37a90704ea09231a308fc6700
Signed-off-by: Daniel R. Carvalho <oda...@yahoo.com.br>
---
M util/style/verifiers.py
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/util/style/verifiers.py b/util/style/verifiers.py
index daf9512..5f87ca4 100644
--- a/util/style/verifiers.py
+++ b/util/style/verifiers.py
@@ -470,7 +470,7 @@
test_name = 'class opening brace position'
opt_name = 'classbrace'
- regex = re.compile(r'\A(\s*)(class\s+[A-Z].*\S)\s*\{')
+ regex = re.compile(r'\A(\s*)((class|struct)\s+[A-Z].*\S)\s*\{')
def check_line(self, line, **kwargs):
return self.regex.search(line) == None
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/43325
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: Ie9d5ccc8f7252ad37a90704ea09231a308fc6700
Gerrit-Change-Number: 43325
Gerrit-PatchSet: 1
Gerrit-Owner: Daniel Carvalho <oda...@yahoo.com.br>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- gem5-dev@gem5.org
To unsubscribe send an email to gem5-dev-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s