How does weathering affect sedimentary rocks?