Fix/suppress system/keymaster google-explicit-constructor warnings
* Add explicit to conversion constructors/operators
* Use NOLINT or NOLINTNEXTLINE to suppress warnings on intended converters
* Some source code format changed by clang-format
Bug: 28341362
Test: make with WITH_TIDY=1 DEFAULT_GLOBAL_TIDY_CHECKS=-*,google-explicit-constructor
Change-Id: Icd9fbdb0ea7bc5b75015b07d73aaa21ae5ee8be7
diff --git a/ng/AndroidKeymaster4Device.cpp b/ng/AndroidKeymaster4Device.cpp
index 69cb6c9..70060d6 100644
--- a/ng/AndroidKeymaster4Device.cpp
+++ b/ng/AndroidKeymaster4Device.cpp
@@ -72,7 +72,7 @@
class KmParamSet : public keymaster_key_param_set_t {
public:
- KmParamSet(const hidl_vec<KeyParameter>& keyParams) {
+ explicit KmParamSet(const hidl_vec<KeyParameter>& keyParams) {
params = new keymaster_key_param_t[keyParams.size()];
length = keyParams.size();
for (size_t i = 0; i < keyParams.size(); ++i) {