clang-tidy: Enable bugprone-unchecked-optional-access
Enable bugprone-unchecked-optional-access to detect the case that it
accesses std::optional without checking empty.
See https://gerrit.openbmc.org/c/openbmc/docs/+/78034 for details.
Signed-off-by: Lei YU <yulei.sh@bytedance.com>
Change-Id: Ia107d6321018ab33ce1073d4dee069eb613fb55e
diff --git a/.clang-tidy b/.clang-tidy
index 5fca7ce..93c4664 100644
--- a/.clang-tidy
+++ b/.clang-tidy
@@ -48,6 +48,7 @@
bugprone-terminating-continue,
bugprone-throw-keyword-missing,
bugprone-too-small-loop-variable,
+bugprone-unchecked-optional-access,
bugprone-undefined-memory-manipulation,
bugprone-undelegated-constructor,
bugprone-unhandled-exception-at-new,