Re: [PATCH gcc/* 1/2] gcc: copy expected and optional out of rust/utils
Jason Merrill <[email protected]>
| Newsgroups | gmane.comp.gcc.jit,gmane.comp.gcc.patches,gmane.comp.gcc.fortran,gmane.comp.gcc.algol68,gmane.comp.gcc.rust |
|---|---|
| Message-ID | <[email protected]> |
On 7/5/26 5:15 PM, Arsen Arsenović wrote: > In my attempts to remove these duplicates from the Rust frontend, I > broke it horribly. So, I'm leaving them in the Rust frontend. Help > wanted! > > gcc/ChangeLog: > > * util/expected.h: New file. Copied out of rust/util. Creating gcc/util seems novel, usually utility headers go directly in gcc/ or in include/. It might also be useful to put these in their own directory to make it clearer that they're imported from the tl libraries, for ease of updating. I suppose that doesn't need to be a top-level directory, perhaps include/tl as in the original repo? > +// You should have received a copy of the CC0 Public Domain Dedication > +// along with this software. If not, see > +// <http://creativecommons.org/publicdomain/zero/1.0/>. I don't think there is such a copy in the GCC sources, is there? This wording seems copied from the GPL notice and much less relevant to CC0, but it's awkward to have this unsatisfied "should". Putting these headers in their own directory will also make it simpler to include such a file. > +/* Includes removed, make sure to include system.h first. */ > +#include "expected_fwd.h" Isn't it OK to keep the includes here as long as system.h gets in first? Are there other local edits to these files? Jason