Decay in landfills is anaerobic and produces methane, which has a higher impact on warming than CO2.
Also, composting has a bunch of other no-brainer benefits. Compost reduces demand for fertilizer, can substantially reduce the waste steam, and improves soil quality.