All-optical cat-code quantum error correction