Fix clang-tidy header filter (#2385)

* Fix clang-tidy header filter

* Allow private members

* Fix clang-tidy detections

* Run clang-format

* Fix remaining detections

* Fix graph

* Run clang-format
This commit is contained in:
Otto Winter
2021-09-24 18:02:28 +02:00
committed by GitHub
parent 52dd79691b
commit aec02afcdc
76 changed files with 404 additions and 367 deletions
+3 -3
View File
@@ -6,7 +6,7 @@ namespace esphome {
#define LOG_PIN(prefix, pin) \
if ((pin) != nullptr) { \
ESP_LOGCONFIG(TAG, prefix "%s", pin->dump_summary().c_str()); \
ESP_LOGCONFIG(TAG, prefix "%s", (pin)->dump_summary().c_str()); \
}
// put GPIO flags in a namepsace to not pollute esphome namespace
@@ -78,7 +78,7 @@ class ISRInternalGPIOPin {
class InternalGPIOPin : public GPIOPin {
public:
template<typename T> void attach_interrupt(void (*func)(T *), T *arg, gpio::InterruptType type) const {
this->attach_interrupt_(reinterpret_cast<void (*)(void *)>(func), arg, type);
this->attach_interrupt(reinterpret_cast<void (*)(void *)>(func), arg, type);
}
virtual void detach_interrupt() const = 0;
@@ -92,7 +92,7 @@ class InternalGPIOPin : public GPIOPin {
virtual bool is_inverted() const = 0;
protected:
virtual void attach_interrupt_(void (*func)(void *), void *arg, gpio::InterruptType type) const = 0;
virtual void attach_interrupt(void (*func)(void *), void *arg, gpio::InterruptType type) const = 0;
};
} // namespace esphome
+1 -1
View File
@@ -37,7 +37,7 @@ void yield();
uint32_t millis();
uint32_t micros();
void delay(uint32_t ms);
void delayMicroseconds(uint32_t us);
void delayMicroseconds(uint32_t us); // NOLINT(readability-identifier-naming)
void __attribute__((noreturn)) arch_restart();
void arch_feed_wdt();
uint32_t arch_get_cpu_cycle_count();
+2 -2
View File
@@ -333,10 +333,10 @@ template<typename T> T *new_buffer(size_t length) {
if (psramFound()) {
buffer = (T *) ps_malloc(length);
} else {
buffer = new T[length];
buffer = new T[length]; // NOLINT(cppcoreguidelines-owning-memory)
}
#else
buffer = new T[length]; // NOLINT
buffer = new T[length]; // NOLINT(cppcoreguidelines-owning-memory)
#endif
return buffer;