From Jason Turner

[temp.mem]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmp73jh6sbo/{from.md → to.md} +9 -19
tmp/tmp73jh6sbo/{from.md → to.md} RENAMED
@@ -69,11 +69,11 @@ int main() {
69
  }
70
  ```
71
 
72
  — *end example*]
73
 
74
- A member function template shall not be virtual.
75
 
76
  [*Example 4*:
77
 
78
  ``` cpp
79
  template <class T> struct AA {
@@ -94,19 +94,21 @@ class B {
94
  virtual void f(int);
95
  };
96
 
97
  class D : public B {
98
  template <class T> void f(T); // does not override B::f(int)
99
- void f(int i) { f<>(i); } // overriding function that calls the template instantiation
100
  };
101
  ```
102
 
103
  — *end example*]
104
 
 
 
105
  A specialization of a conversion function template is referenced in the
106
  same way as a non-template conversion function that converts to the same
107
- type.
108
 
109
  [*Example 6*:
110
 
111
  ``` cpp
112
  struct A {
@@ -123,23 +125,11 @@ int main() {
123
  }
124
  ```
125
 
126
  — *end example*]
127
 
128
- [*Note 1*: There is no syntax to form a *template-id* [[temp.names]] by
129
- providing an explicit template argument list [[temp.arg.explicit]] for a
130
- conversion function template [[class.conv.fct]]. — *end note*]
131
 
132
- A specialization of a conversion function template is not found by name
133
- lookup. Instead, any conversion function templates visible in the
134
- context of the use are considered. For each such operator, if argument
135
- deduction succeeds [[temp.deduct.conv]], the resulting specialization is
136
- used as if found by name lookup.
137
-
138
- A *using-declaration* in a derived class cannot refer to a
139
- specialization of a conversion function template in a base class.
140
-
141
- Overload resolution [[over.ics.rank]] and partial ordering
142
- [[temp.func.order]] are used to select the best conversion function
143
- among multiple specializations of conversion function templates and/or
144
- non-template conversion functions.
145
 
 
69
  }
70
  ```
71
 
72
  — *end example*]
73
 
74
+ A member function template shall not be declared `virtual`.
75
 
76
  [*Example 4*:
77
 
78
  ``` cpp
79
  template <class T> struct AA {
 
94
  virtual void f(int);
95
  };
96
 
97
  class D : public B {
98
  template <class T> void f(T); // does not override B::f(int)
99
+ void f(int i) { f<>(i); } // overriding function that calls the function template specialization
100
  };
101
  ```
102
 
103
  — *end example*]
104
 
105
+ [*Note 1*:
106
+
107
  A specialization of a conversion function template is referenced in the
108
  same way as a non-template conversion function that converts to the same
109
+ type [[class.conv.fct]].
110
 
111
  [*Example 6*:
112
 
113
  ``` cpp
114
  struct A {
 
125
  }
126
  ```
127
 
128
  — *end example*]
129
 
130
+ There is no syntax to form a *template-id* [[temp.names]] by providing
131
+ an explicit template argument list [[temp.arg.explicit]] for a
132
+ conversion function template.
133
 
134
+ *end note*]
 
 
 
 
 
 
 
 
 
 
 
 
135