RFR: 8234779: Provide idiom for declaring classes noncopyable

Kim Barrett kim.barrett at oracle.com
Tue Dec 3 19:49:16 UTC 2019


> On Dec 3, 2019, at 3:04 AM, David Holmes <david.holmes at oracle.com> wrote:
> 
> Hi Kim,
> 
> There is a bit of an include file inconsistency, but not your fault. In places you have added:
> 
> #include "utilities/globalDefinitions.hpp"
> 
> to files that should already (but don't) include macros.hpp. And globalDefinitions.hpp itself includes macros.hpp which "fixes" that. But then in other places we have:
> 
> +#include "utilities/globalDefinitions.hpp"
> #include "utilities/macros.hpp"
> 
> Either all sites should include both files or else only globalDefinitions.hpp. But perhaps a later cleanup.

Not all places that #include globalDefinitions.hpp need to
explicitly #include macros.hpp. To avoid implicit #include
dependencies macros.hpp ought to be directly #included if the file
directly uses definitions from there. I'm sure there are files that
use things from globalDefinitions.hpp but not from macros.hpp. I'm
equally sure there are files that ought to be directly including one
or the other, or both, but aren't. Addressing and maintaining that
would require some significant work, probably involving adding some
tooling similar to
https://github.com/include-what-you-use/include-what-you-use
to our build process.



More information about the hotspot-dev mailing list