Dust-enshrouded giants in clusters in the Magellanic Clouds