[ld2412] Use a user provided default constructor for EngineeringModeSwitch (#19190)

This commit is contained in:
J. Nick Koston
2026-09-16 18:20:10 +12:00
committed by GitHub
parent b0f87615a2
commit 43e35c4fc2
@@ -7,7 +7,8 @@ namespace esphome::ld2412 {
class EngineeringModeSwitch final : public switch_::Switch, public Parented<LD2412Component> {
public:
EngineeringModeSwitch() = default;
// User provided, not "= default": `new(p) EngineeringModeSwitch()` would zero-fill .bss that is already zero.
EngineeringModeSwitch() {}
protected:
void write_state(bool state) override;