// Note: we can't add `impl<T: Float> Pow<T> for Complex<T>` because new blanket impls are a // breaking change. Someone could already have their own `F` and `impl Pow<F> for Complex<F>` // which would conflict. We can't even do this in a new semantic version, because we have to // gate it on the "std" feature, and features can't add breaking changes either.
macro_rules! powf_impl {
($F:ty) => { #[cfg(any(feature = "std", feature = "libm"))] impl<'a, T: Float> Pow<$F> for &'a Complex<T> where
$F: Into<T>,
{ type Output = Complex<T>;
// These blanket impls are OK, because both the target type and the trait parameter would be // foreign to anyone else trying to implement something that would overlap, raising E0117.
#[cfg(any(feature = "std", feature = "libm"))] impl<'a, T: Float> Pow<Complex<T>> for &'a Complex<T> { type Output = Complex<T>;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.