Don't warn about functions not emitted

If a function is used by a template but this template is not
instantiated, the function will still be defined in the header
of a module but it won't be callable because it is in an anonymous
namespace and thus we get a warning.

This only happens in Clang; GCC consider functions referenced from
templates as used.

fixup! Don't warn about functions not emitted
This commit is contained in:
Roland Kaufmann 2013-09-19 10:59:41 +02:00
parent 5f00467f02
commit 1341903bb7

View File

@ -40,6 +40,8 @@ namespace Opm
namespace
{
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wunneeded-internal-declaration"
// Find the cells that are below and above a depth.
// TODO: add 'anitialiasing', obtaining a more precise split
// by f. ex. subdividing cells cut by the split depths.
@ -61,6 +63,7 @@ namespace Opm
}
}
}
#pragma clang diagnostic pop
enum WaterInit { WaterBelow, WaterAbove };