New Issue: Add support for slicing sparse domain with dense

16744, “bradcray”, “Add support for slicing sparse domain with dense”, “2020-11-19T01:48:05Z”

Today, when slicing a sparse domain with a dense domain, we get a dense domain result. For example:

config const n = 10;

var D = {1..n, 1..n};
var SD: sparse subdomain(D) = [i in 1..n] (i,i);

writeln(SD[{3..5, 3..5}]);  // or `SD[3..5, 3..5]`

evaluates to a dense domain and prints {3..5, 3..5} when it should evalute to a sparse domain describing the subset of SD within the {3…5, 3…5} bounding box. This isn’t consistent with domain slicing meaning intersection and isn’t particularly useful.