Sedimentary because Sediments are produced when rocks are uplifted, weathered and eroded, and the resulting detrital material deposited in marine or terrestrial basins. If the sediments are buried under further layers of sediment, they can become lithified to produce a sedimentary rock. Magma is produced when rocks are melted.