📜  gcc 抑制内联警告 - C++ 代码示例

📅  最后修改于: 2022-03-11 14:44:56.314000             🧑  作者: Mango

代码示例1
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"

void f(int a, int b)
{
    std::cout << a << '\n';
    // we are not using b!
}

#pragma GCC diagnostic pop