clang-tidy: Enable readability-const-return-type check
Checks for functions with a const-qualified return type and
recommends removal of the const keyword. Such use of const is usually
superfluous, and can prevent valuable compiler optimizations. Does
not (yet) fix trailing return types.
Signed-off-by: George Liu <liuxiwei@ieisystem.com>
Change-Id: Ifff7541c95d7881d8c6407b20c906ec7eb13abf1
diff --git a/.clang-tidy b/.clang-tidy
index 3e07c71..c3291cd 100644
--- a/.clang-tidy
+++ b/.clang-tidy
@@ -253,6 +253,7 @@
performance-trivially-destructible,
performance-type-promotion-in-math-fn,
performance-unnecessary-copy-initialization,
+readability-const-return-type,
readability-delete-null-pointer,
readability-deleted-default,
readability-function-size,