6 Commits

Author SHA1 Message Date
Timm Bäder
d16cf470ac [clang][Interp] Start implementing binary operators for complex types
Differential Revision: https://reviews.llvm.org/D155572
2023-12-14 15:33:52 +01:00
Timm Bäder
88abd530ef [clang][Interp] Allow evaluating standalone complex expressions
We reach visitExpr() when evaluating standalone expressions. However,
the RetValue() code path was unused before, because we never reach it,
even with structs or arrays.

RetValue expects a pointer on the stack it can take apart to return an
APValue, so provide it with one.

Differential Revision: https://reviews.llvm.org/D150661
2023-12-14 15:07:42 +01:00
Timm Bäder
935f5ee9c9 [clang][Interp] ComplexFloatingToBoolean casts
Differential Revision: https://reviews.llvm.org/D150654
2023-12-14 13:17:40 +01:00
Timm Bäder
497480b38a [clang][Interp] IntegralComplexToBoolean casts
Differential Revision: https://reviews.llvm.org/D148426
2023-12-14 13:11:00 +01:00
Timm Bäder
07e3c245ba [clang][Interp] Support empty initlist initializers for complex types
Differential Revision: https://reviews.llvm.org/D147369
2023-12-14 12:53:40 +01:00
Timm Bäder
797fee68d1 [clang][Interp] Start supporting complex types
Differential Revision: https://reviews.llvm.org/D146408
2023-12-14 11:57:38 +01:00