The EU has set a target of net-zero greenhouse-gas emissions by 2050, a goal that will be enshrined in law to be put on the table next March.