Shaving Mug
Shaving used to be a ritual for men. Today, most men shave with an electronic trimmer or an electronic razor, but in the past, men used to shave with a razor or a shaving brush and soap. It was a whole ritual, that included several gadgets, such as the traditional shaving mug – in the picture below. These days, young men (and women) wouldn’t even recognize this item.
When the OP found this cup in their family’s collection of fine chinaware, they were confused as to why a cup would be half-closed and have holes punched into the half-lid. As a helpful Reddit user explained, this is a shaving mug. As you can probably guess, for convenience, the soap rests on the shelf with the drainage holes, and the cup contains hot water.