RFR: 8296926: Sort include lines of files in the include/ directory [v4]

David Holmes dholmes at openjdk.org
Thu Nov 17 02:32:52 UTC 2022


On Wed, 16 Nov 2022 11:05:59 GMT, Stefan Karlsson <stefank at openjdk.org> wrote:

>> One of the more prevalent issues is that files in src/hotspot/share/include are not properly sorted. There has been some discussion that that was done on purpose, but it just adds another exception to the include rules that don't have any practical purposes, IMHO. It also goes against our written style guide around include files. One argument why it was OK have the files in include/ pushed up to the top of the sorted block, was that the file was included without specifying a directory. That's an argument that contradicts how we treat platform-dependent files, which (unfortunately) often also are specified without a prefixed directory. To remove this special case, I've removed the extraneous make file entry to have src/hotspot/share/include in the set of directories to search for headers when compiling HotSpot. Now all the header files in src/hotspot/share/include gets included by specifying the path from src/hotspot/share, just like the other platform-independent headers in HotSpo
 t.
>> 
>> This RFE splits out the 'include/' changes from #11108 / JDK-8296886, so that those changes can be discussed separately.
>
> Stefan Karlsson has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:
> 
>  - Remove include/ from test/hotspot files
>  - Merge remote-tracking branch 'upstream/master' into 8296926_proper_include_lines_for_include_dir_files
>  - Revert make file changes
>  - Remove include/ from includes
>  - 8296926: Use proper include lines for files in include/

Sorry I didn't get a chance to look at this yesterday. A belated "thumbs up".

-------------

PR: https://git.openjdk.org/jdk/pull/11133


More information about the serviceability-dev mailing list