Isn't it interesting how we say, "cup of coffee" but "glass of water"?
I was thinking this morning about how I had already had a cup of coffee and a glass of water to drink. The reason I stopped to think about the phrasing is because I didn't actually have the water in a glass. I was filling a water bottle to take to work and stopped to have a drink from it before refilling it to take with me. But the only phrase that came to mind was 'a glass of water'.
And technically, my coffee was in a mug.