Heat the olive oil in a wide skillet over medium heat until it shimmers. Add the carrots, season with salt and pepper, and stir to coat.
After a few minutes, add the brown sugar and molasses and stir as they melt into a glaze.
Add water a little at a time as the carrots soften, simmering until the sauce is thick and glossy and the carrots are tender but still have a little bite.
Stir in the butter and rosemary sprig. Once the butter melts and the rosemary is fragrant, remove and discard the rosemary.
Transfer to a serving dish and garnish with chopped carrot greens or parsley.