A user may reference a function from global namespace in friend
declaration, which returns enum or class, as in example:
enum E { A, B };
E func();
namespace N {
class C {
friend E ::func();
};
}This is wrong as the identifier following '::' must be considered
as a part of nested-name-specifier.
This change implements additional note in such case with a hint to put
parenthesis around the function qualified name.
It fixes PR28422 (https://llvm.org/bugs/show_bug.cgi?id=28422).