-
- Downloads
[MLIR][Presburger] Make constructors from PresburgerSpace explicit
This patch makes constructors of IntegerRelation, IntegerPolyhedron, PresburgerRelation, PresburgerSet from PresburgerSpace explicit. This prevents bugs like: ``` void fun(IntegerRelation a, IntegerRelation b) { IntegerPolyhedron c = a.intersect(b); } ``` Here, `a.intersect(b)` will return `IntegerRelation`, which will be implicitly converted to `PresburgerSpace` and will use the `PresburgerSpace` constructor for IntegerPolyhedron. Leading to loss of any constraints in the intersection of `a` and `b`. After this patch, this will give a compile error. Reviewed By: arjunp Differential Revision: https://reviews.llvm.org/D122972
Loading
Please register or sign in to comment