Handle unioning and intersecting with empty ranges (#223, #224)