Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

gcc suppress warning inline

#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"

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

#pragma GCC diagnostic pop
Source by www.fluentcpp.com #
 
PREVIOUS NEXT
Tagged: #gcc #suppress #warning #inline
ADD COMMENT
Topic
Name
3+4 =