Hi All,
I just added a declaration in WTF/wtf/DataLog.h, like what we commonly do
in C:
================
namespace WTF{
...
WTF_EXPORT_PRIVATE extern int abc;
...
}
using WTF::abc;
================
Of course, DataLog.cpp has the actual declaration.
However, when compiling with Clang, it emits an error : "declaration
requires a global constructor". I am quite confused about the error
message. How can I write a constructor for abc?
I just want the variable abc to be visible as "dataLog" does. Thanks.
Best
Wei
_______________________________________________
webkit-dev mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-dev