From 57a60c832bafedfaf2a4b51a5b3beeeb9dfd02d9 Mon Sep 17 00:00:00 2001 From: Nikolaj Bjorner Date: Wed, 13 Aug 2025 10:24:12 -0700 Subject: [PATCH] add > operator as shorthand for Array --- src/api/python/z3/z3.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/api/python/z3/z3.py b/src/api/python/z3/z3.py index 16cc45de2..9a9fe5e4a 100644 --- a/src/api/python/z3/z3.py +++ b/src/api/python/z3/z3.py @@ -653,6 +653,10 @@ class SortRef(AstRef): """ return not Z3_is_eq_sort(self.ctx_ref(), self.ast, other.ast) + def __gt__(self, other): + """Create the function space Array(self, other)""" + return ArraySort(self, other) + def __hash__(self): """ Hash code. """ return AstRef.__hash__(self)