This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of TC1 status.

79. Inconsistent declaration of polar()

Section: 24.5.1 [complex.syn], 24.5.7 [complex.value.ops] Status: TC1 Submitter: Nico Josuttis Opened: 1998-09-29 Last modified: 2016-02-10

Priority: Not Prioritized

View all other issues in [complex.syn].

View all issues with TC1 status.

Discussion:

In 24.5.1 [complex.syn] polar is declared as follows:

   template<class T> complex<T> polar(const T&, const T&); 

In 24.5.7 [complex.value.ops] it is declared as follows:

   template<class T> complex<T> polar(const T& rho, const T& theta = 0); 

Thus whether the second parameter is optional is not clear.

Proposed resolution:

In 24.5.1 [complex.syn] change:

   template<class T> complex<T> polar(const T&, const T&);

to:

   template<class T> complex<T> polar(const T& rho, const T& theta = 0);