From e390f9f618ec694e5327ebe93cdfc0ba89ab5a86 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Sun, 20 Sep 2020 20:28:56 +0300 Subject: Documentation: Adjust guidelines regarding math.h header MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit While libcamera prefers usage of the C standard library headers (xxx.h) over the C++ version (cxxx), we make an exception for cmath as the overloaded versions of the math functions are convenient. Document this, and adjust checkstyle.py accordingly. Signed-off-by: Laurent Pinchart Reviewed-by: Jacopo Mondi Reviewed-by: Niklas Söderlund --- utils/checkstyle.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'utils') diff --git a/utils/checkstyle.py b/utils/checkstyle.py index b594a19a..d5dc26c0 100755 --- a/utils/checkstyle.py +++ b/utils/checkstyle.py @@ -244,9 +244,9 @@ class IncludeChecker(StyleChecker): patterns = ('*.cpp', '*.h') headers = ('assert', 'ctype', 'errno', 'fenv', 'float', 'inttypes', - 'limits', 'locale', 'math', 'setjmp', 'signal', 'stdarg', - 'stddef', 'stdint', 'stdio', 'stdlib', 'string', 'time', 'uchar', - 'wchar', 'wctype') + 'limits', 'locale', 'setjmp', 'signal', 'stdarg', 'stddef', + 'stdint', 'stdio', 'stdlib', 'string', 'time', 'uchar', 'wchar', + 'wctype') include_regex = re.compile('^#include ') def __init__(self, content): -- cgit v1.2.1