1、打开设置
2、添加C++11
3、测试以下代码,运行成功即可
#include <cstring>
#include <cstdio>
#include <iostream>
#include <iostream>
#include <tuple>
#include <memory>
void abcd(int &a)
{
std::cout <<"abc1:"<< a << std::endl;
}
void abc(int &&a)
{
std::cout <<"abc2:"<< a << std::endl;
}
template<typename T>
void f1(const T&& a)
{
printf("f1:%d\n",a);
}
int main()
{
printf("aa\n");
f1(4);
//int a = 1;
//abc(3);
//abc(1);
}
标签:11,f1,CodeRunner,int,C++,printf,include
From: https://www.cnblogs.com/zhaogaojian/p/17133684.html