Boost logo

Ublas :

Subject: Re: [ublas] enable complex @ int
From: Matwey V. Kornilov (matwey.kornilov_at_[hidden])
Date: 2009-09-29 09:17:42


>> I think it would be better to write in such way:
>>
>> template<R> std::complex<R> operator+ (int in1, const std::complex<R>&
>> in2 ){
>> return typename std::complex<R>::value_type(in1) + in2;
>> }
>>
>>
> That wouldn't conflict with stdlib?

It is just your version that has been extended for both complex<float> and
complex<double>.