mirror of
https://github.com/esphome/esphome.git
synced 2026-02-28 18:04:19 -07:00
b8a6deddf54b6ccadc8b8b313763866c51bc2357
When no text sensor filters are configured, the entire Filter class hierarchy (filter.h/filter.cpp) was still compiled and linked. This pulled in std::string manipulation code (_M_mutate, _M_create, _M_append, _M_replace, _M_assign, _M_dispose) that is only needed for filter chain processing. Add USE_TEXT_SENSOR_FILTER define that is only emitted when at least one text sensor has filters configured. Wrap filter-related code behind this define to eliminate dead code from the binary. Saves ~340 bytes of flash on configs with filterless text sensors.
Description
ESPHome is a system to control your ESP8266/ESP32 by simple yet powerful configuration files and control them remotely through Home Automation systems.
Readme
Multiple Licenses
518 MiB
Languages
C++
64.1%
Python
35.5%
C
0.3%
