The BS5839 P6 used to say (not 100% sure if this is still correct) that smoke detectors fed from a dedicated circuit need not have battery backup, but if fed from a local lighting circuit they must have battery backup.
I always thought this to be backward thinking.
I lighting circuit failing will be addressed as a matter of urgency, and power restored to the alarms. I dedicated circuit failing would not be noted so quickly, and unlikely to be addressed with haste. Battery backup would surely be more preferred on the dedicated circuit rather than the lighting circuit.