You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: test/src/example.h
+16Lines changed: 16 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -205,4 +205,20 @@ class ExampleAbstract : public Object {
205
205
staticvoid_bind_methods() {}
206
206
};
207
207
208
+
template <classT>
209
+
classExampleTemplated : publicObject {
210
+
GDCLASS_TEMPLATE(ExampleTemplated, Object);
211
+
212
+
T number = (T)42;
213
+
214
+
protected:
215
+
staticvoid_bind_methods();
216
+
217
+
T get_number();
218
+
};
219
+
220
+
// To suppress warning: instantiation of variable 'ExampleTemplated<int>::_template_class_name' required here, but no definition is available [-Wundefined-var-template]
0 commit comments