Do all explosions produce carbon dioxide?
It is possible, however, to explode substances that do not contain carbon, such as pure hydrogen (the very famous Hindenburg disaster in 1937 is a classic example of a very big hydrogen gas explosion -- see the Web Links to the left of this answer for more about that and an impressive video -- skip ahead to 3:30 min to see the explosion!). An explosion of hydrogen produces only water vapor (H2O), NOT carbon dioxide (CO2). SO2, sulfur dioxide, is also commonly ford when sulfur is burned instead of carbon. Azide salts like NaN3 are commonly used to explosively inflate car airbags. On detonation, they decompose to the elemental metal. This is a favourable transition due to a positive change and the formation of highly stable free nitrogen gas.
Also, nuclear (both fusion and fission) themselves do not produce carbon dioxide, although they may cause surrounding objects to incinerate, which would release carbon dioxide.
See the Web Links to the left of this answer for some impressive videos of different types of explosions, including ones that do and don't produce CO2 emissions!