Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion array_api_tests/dtype_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,14 @@ def result_type(*dtypes: DataType):


r_alias = re.compile("[aA]lias")
r_in_dtypes = re.compile("x1?: array\n.+have an? (.+) data type.")

r_in_dtypes = re.compile(
r'(?:x(?:1)?: (?:Union\[)?array(?:, (?:int|float|complex|bool))*(?:\])?\s*\n.+?'
r'(?:x2: (?:Union\[)?array(?:, (?:int|float|complex|bool))*(?:\])?\s*\n.+?)?)?'
r'Should have an? (boolean|integer or boolean|real-valued floating-point|complex floating-point|real-valued|floating-point|integer|numeric) data type\.',
re.DOTALL
)

r_int_note = re.compile(
"If one or both of the input arrays have integer data types, "
"the result is implementation-dependent"
Expand Down