Skip to content

Build switches: unconditionally add -gnatW8#972

Merged
mosteo merged 3 commits into
masterfrom
gnatW8
Sep 29, 2022
Merged

Build switches: unconditionally add -gnatW8#972
mosteo merged 3 commits into
masterfrom
gnatW8

Conversation

@Fabien-Chouteau

Copy link
Copy Markdown
Member

@Fabien-Chouteau Fabien-Chouteau requested a review from mosteo April 6, 2022 14:58
@mosteo

mosteo commented Apr 7, 2022

Copy link
Copy Markdown
Member

I'm in favor of all things Unicode/UTF-8. I do remember however some discussions about this on c.l.a. about things not working out so seamlessly.

See https://groups.google.com/g/comp.lang.ada/c/l0aflBePm_E/m/BUtW96RhAgAJ and following discussion.

I'm leaving this here before merging for a while just in case, with the idea of merging it for the next release if we found no objection. I admit to having no experience with the issue.

@mosteo mosteo added this to the Next milestone Apr 7, 2022
@Fabien-Chouteau

Copy link
Copy Markdown
Member Author

After some further discussion, the risk of introducing incompatibilities is too high to make this the default switch.

@reznikmm

reznikmm commented Sep 19, 2022

Copy link
Copy Markdown
Contributor

After some further discussion, the risk of introducing incompatibilities is too high to make this the default switch.

Could you elaborate? What incompatibilities did you find?

I've compiled these two files and got exactly assembler output:

package Pkg is
   ["03C0"] : Integer;
end Pkg;
gcc -S pkg.ads
mv pkg.s pkg.s_
package Pkg is
   π : Integer;
end Pkg;
gcc -S -gnatW8 -gnatwi pkg.ads
diff -u pkg.s pkg.s_

@Fabien-Chouteau

Copy link
Copy Markdown
Member Author

-gnatW8 tells GNAT to decode sources as UTF-8 for the sources to compile, but also all their dependencies, so when building crate A, this will also affect the processing of the dependency crate B

@Fabien-Chouteau Fabien-Chouteau restored the gnatW8 branch September 29, 2022 12:26
@mosteo mosteo merged commit 54174b7 into master Sep 29, 2022
@mosteo mosteo deleted the gnatW8 branch September 29, 2022 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants