#include <iostream>
struct Example {
void Foo(int value) {
std::cout << "Foo(int value) = " << value << std::endl;
}
template <typename T>
void Foo(T value) = delete;
};
int main() {
Example e;
int a = 18493;
e.Foo(a);
unsigned int b = 18493;
e.Foo(b);
}
/*
run:
main.cpp:19:10: error: use of deleted function 'void Example::Foo(T) [with T = unsigned int]'
19 | e.Foo(b);
| ~~~~~^~~
*/