Title
Equivalent and functionally-equivalent function templates
Status
tc1
Section
17.6.6.1 [temp.over.link]
Submitter
Mike Miller

Created on 1999-05-11.00:00:00 last changed 208 months ago

Messages

Date: 1999-10-15.00:00:00

Proposed resolution (10/99): Remove the three uses of the words "non-type" in 17.6.6.1 [temp.over.link] paragraph 7.

Date: 2004-09-10.00:00:00

17.6.6.1 [temp.over.link] , paragraphs 5 and 6, describes equivalence and functional equivalence for expressions involving template parameters. As a note in paragraph 5 points out, such expressions may involve type parameters as well as non-type parameters.

Paragraph 7, however, describes the equivalence of function templates only with respect to non-type template parameters. It appears to be unspecified how to determine the equivalence of template functions whose types involve expressions that use template type parameters.

    template <int I> struct S { };

    // The following two declarations are equivalent:
    template <int I> void f(S<I>);
    template <int J> void f(S<J>);

    // The IS doesn't say whether these are equivalent:
    template <class T> void f(S<sizeof(T)>);
    template <class T> void f(S<sizeof(T)>);
History
Date User Action Args
2003-04-25 00:00:00adminsetstatus: dr -> tc1
2000-05-21 00:00:00adminsetstatus: open -> dr
2000-02-23 00:00:00adminsetmessages: + msg302
1999-05-11 00:00:00admincreate