mirror of
				https://github.com/esphome/esphome.git
				synced 2025-10-30 22:53:59 +00:00 
			
		
		
		
	Activate some clang-tidy checks (#1884)
This commit is contained in:
		| @@ -12,14 +12,14 @@ const extern float COVER_OPEN; | ||||
| const extern float COVER_CLOSED; | ||||
|  | ||||
| #define LOG_COVER(prefix, type, obj) \ | ||||
|   if (obj != nullptr) { \ | ||||
|     ESP_LOGCONFIG(TAG, "%s%s '%s'", prefix, type, obj->get_name().c_str()); \ | ||||
|     auto traits_ = obj->get_traits(); \ | ||||
|   if ((obj) != nullptr) { \ | ||||
|     ESP_LOGCONFIG(TAG, "%s%s '%s'", prefix, type, (obj)->get_name().c_str()); \ | ||||
|     auto traits_ = (obj)->get_traits(); \ | ||||
|     if (traits_.get_is_assumed_state()) { \ | ||||
|       ESP_LOGCONFIG(TAG, "%s  Assumed State: YES", prefix); \ | ||||
|     } \ | ||||
|     if (!obj->get_device_class().empty()) { \ | ||||
|       ESP_LOGCONFIG(TAG, "%s  Device Class: '%s'", prefix, obj->get_device_class().c_str()); \ | ||||
|     if (!(obj)->get_device_class().empty()) { \ | ||||
|       ESP_LOGCONFIG(TAG, "%s  Device Class: '%s'", prefix, (obj)->get_device_class().c_str()); \ | ||||
|     } \ | ||||
|   } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user