Complex representation of the constant.
(self)
| 91 | return float(self.value) |
| 92 | |
| 93 | def __complex__(self) -> complex: |
| 94 | """Complex representation of the constant.""" |
| 95 | if self.ufl_shape or self.ufl_free_indices: |
| 96 | raise TypeError("Cannot evaluate a nonscalar expression to a scalar value.") |
| 97 | |
| 98 | return complex(self.value) |
| 99 | |
| 100 | |
| 101 | class Expression(Generic[Scalar]): |
nothing calls this directly
no outgoing calls
no test coverage detected