Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

C++ module support #8013

Merged
merged 7 commits into from Dec 14, 2020
Merged

C++ module support #8013

merged 7 commits into from Dec 14, 2020

Conversation

jpakkane
Copy link
Member

@jpakkane jpakkane commented Nov 21, 2020

This MR adds support for compiling C++ modules, which are similar to Fortran modules requiring one to scan the contents of files. This is done with the new Ninja dynamic dependency support that is only available in the latest releases. There are several limitations.

  • only works with Visual Studio 2019 developer preview
  • only supports basic "ixx" modules, not module partitions et al

There are also open questions such as where should the generated module files go. Should they go in target private dirs or to a single common dir? The latter is easier and works if we can rely on the fact that no module of a given name is generated in two different places. Currently all those are dumped in build dir root, because MS has not yet documented the compiler flags that specify where those should go (if said compiler flags exist at all).

@jpakkane jpakkane requested a review from dcbaker as a code owner Nov 21, 2020
@lgtm-com
Copy link

@lgtm-com lgtm-com bot commented Nov 21, 2020

This pull request introduces 1 alert when merging 12952c4 into 15bbf1e - view on LGTM.com

new alerts:

  • 1 for Unused local variable

@lgtm-com
Copy link

@lgtm-com lgtm-com bot commented Dec 11, 2020

This pull request introduces 1 alert when merging 6686bcf into b65168c - view on LGTM.com

new alerts:

  • 1 for Unused local variable

@lgtm-com
Copy link

@lgtm-com lgtm-com bot commented Dec 11, 2020

This pull request introduces 1 alert when merging 9731b0e into b65168c - view on LGTM.com

new alerts:

  • 1 for Unused local variable

@lgtm-com
Copy link

@lgtm-com lgtm-com bot commented Dec 11, 2020

This pull request introduces 1 alert when merging 07c70e7 into 8d04b3c - view on LGTM.com

new alerts:

  • 1 for Unused local variable

@jpakkane jpakkane force-pushed the cppmodules branch 2 times, most recently from ca808a0 to ba725f0 Compare Dec 12, 2020
@jpakkane jpakkane changed the title WIP: C++ module support C++ module support Dec 12, 2020
@jpakkane
Copy link
Member Author

@jpakkane jpakkane commented Dec 12, 2020

This should pass all the tests now. The actual functionality is fairly small, but the machinery is important and can be used to make Fortran compilation finally reliable.

@jpakkane jpakkane force-pushed the cppmodules branch 2 times, most recently from aab28fa to 2fafb73 Compare Dec 13, 2020
@jpakkane jpakkane merged commit 9f1ba40 into master Dec 14, 2020
40 checks passed
@jpakkane jpakkane deleted the cppmodules branch Dec 14, 2020
@willwray willwray mentioned this pull request Jan 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

1 participant