aboutsummaryrefslogtreecommitdiff
path: root/contrib
AgeCommit message (Collapse)AuthorFilesLines
2020-05-22Fix up go related ignored locations.Jakub Jelinek2-2/+8
2020-05-22 Jakub Jelinek <jakub@redhat.com> * gcc-changelog/git_commit.py: Add trailing / to gcc/testsuite/go.test/test and replace gcc/go/frontend/ with gcc/go/gofrontend/ in ignored locations.
2020-05-22Add missing ChangeLog entry.Martin Liska1-0/+5
2020-05-22Add gcc/testsuite/go.test/test to ignored locations for gcc_commit.py.Martin Liska1-0/+1
contrib/ChangeLog: 2020-05-22 Martin Liska <mliska@suse.cz> * gcc-changelog/git_commit.py: Add gcc/testsuite/go.test/test to ignored locations.
2020-05-21Prepare git_update_version.py for real usage.Martin Liska2-9/+13
* gcc-changelog/git_update_version.py: Prepare the script, the only missing piece is pushing of the updated branches.
2020-05-21Support DR entries for gcc-changelog.Martin Liska4-1/+41
* gcc-changelog/git_commit.py: Support DR entries/ * gcc-changelog/test_email.py: New test for it. * gcc-changelog/test_patches.txt: New patch for it.
2020-05-21mklog: support parsing of DR.Martin Liska3-1/+52
* mklog.py: Support DR parsing. * test_mklog.py: New test for DR parsing.
2020-05-20git_email.py: fix duplicate author_lines.Martin Liska4-1/+110
* gcc-changelog/git_commit.py: Add author_tuple only if not present in author_lines. * gcc-changelog/test_email.py: New test. * gcc-changelog/test_patches.txt: Add new patch.
2020-05-20git_commit.py: Add tests for signatures.Martin Liska4-2/+47
* gcc-changelog/git_commit.py: Refactor to make flake8 happy. * gcc-changelog/test_email.py: Add new test. * gcc-changelog/test_patches.txt: Add new patch.
2020-05-20contrib/gcc-changelog: Skip over review linesFrederik Harwath2-1/+15
git-check-commit.py does not know about "Reviewed-by", "Reviewed-on", and "Signed-off-by" lines and hence it expects those lines which follow the ChangeLog entries to be indented by a tab. This commit makes the script skip those lines. No further processing is attempted because the review information is not part of the ChangeLogs. contrib/ 2020-05-20 Frederik Harwath <frederik@codesourcery.com> * gcc-changelog/git_commit.py: Skip over lines starting with "Reviewed-by: ", "Reviewed-on: ", or "Signed-off-by: "
2020-05-20git_check_commit: shorted option nameMartin Liska2-4/+9
* gcc-changelog/git_check_commit.py: Change --allow-non-strict-mode to --non-strict-mode.
2020-05-20Add gcc-backport and support git cherry pick.Martin Liska5-0/+45
* gcc-changelog/git_commit.py: Support cherry pick prefix. * gcc-changelog/test_email.py: Test it. * gcc-changelog/test_patches.txt: Add new patch. * gcc-git-customization.sh: Add gcc-backport.
2020-05-19Use REST API for bug titles in mklog.Martin Liska2-11/+13
* mklog.py: Use REST API for bug title downloading.
2020-05-19Use commit timestamp in git_update_version.py.Martin Liska3-3/+9
* gcc-changelog/git_commit.py: Add param use_commit_ts for to_changelog_entries. * gcc-changelog/git_update_version.py: Se use_commit_ts to True.
2020-05-19mklog.py: improve parsing of struct names (ignore GTY).Martin Liska3-4/+42
* mklog.py: Skip GTY for struct names. Make flake8 happy. * test_mklog.py: Add test for GTY.
2020-05-19Add missing changelog entry.Martin Liska1-0/+5
2020-05-19Fill up entries in reverse order.Martin Liska1-1/+1
contrib/ChangeLog: * gcc-changelog/git_update_version.py: Fill up entries in reverse order.
2020-05-19New mklog script.Martin Liska4-0/+577
contrib/ChangeLog: 2020-05-15 Martin Liska <mliska@suse.cz> * gcc-git-customization.sh: Add alias.gcc-mklog new hook. * mklog.py: New file. * test_mklog.py: New file.
2020-05-19Move 2 mklog scripts to legacy subfolder.Martin Liska3-0/+5
contrib/ChangeLog: * legacy/mklog: Moved from mklog. * legacy/mklog.pl: Moved from mklog.pl.
2020-05-19Add gcc-verify alias.Martin Liska2-0/+7
* gcc-git-customization.sh: Add gcc-verify alias that uses contrib/gcc-changelog/git_check_commit.py.
2020-05-15contrib: Handle GDB specific test result typesAndrew Burgess3-3/+20
This commit is for the benefit of GDB, but as the binutils-gdb repository shares the contrib/ directory with gcc, this commit must first be applied to gcc then copied back to binutils-gdb. This commit extends the two scripts contrib/dg-extract-results.{py,sh} to handle some new, GDB specific test result types. These test results types should never appear in GCC, or any other tool that shares the contrib/ directly, so this change should be harmless. In this patch series: https://sourceware.org/pipermail/gdb-patches/2020-April/167847.html changes were made in GDB's use of Dejagnu so that two additional conditions could be detected, these are: 1. Test names that contain either the build or source paths. Such test names make it difficult to compare the results of two test runs of GDB from two different directories, and 2. Duplicate test names. Duplicates make it difficult to track down exactly which test has failed. When running Dejagnu on GDB we can now (sometimes) see two additional test result types matching the above conditions, these are '# of paths in test names' and '# of duplicate test names'. If the test is run in parallel mode (make -j...) then these extra test results will appear in the individual test summary files, but are not merged into the final summary file. Additionally, within the summary file there are now two new types of test summary line, these are 'PATH: ...' and 'DUPLICATE: ...', these allow users to quickly search the test summary to track down where the offending test names are. These lines are similarly not merged into the unified gdb.sum file after a parallel test run. This commit extends the dg-extract-results.* scripts to calculate the totals for the two new result types, and to copy the new test summary lines into the unified summary file. contrib/ChangeLog: * dg-extract-results.py: Handle GDB specific test types. * dg-extract-results.sh: Likewise.
2020-05-14Add tests for gcc-changelog.Martin Liska3-0/+2649
* gcc-changelog/test_email.py: New file. * gcc-changelog/test_patches.txt: New file.
2020-05-13contrib/vimrc: Reduce textwidth for commit messagesPatrick Palka2-1/+9
* vimrc: Reduce textwidth to 72 for Git commit messages.
2020-05-13Add default revisions argument for git_check_commit.py.Martin Liska2-3/+8
* gcc-changelog/git_check_commit.py: Add default argument HEAD for revisions and improve error message output.
2020-05-13Restore print_output syntax in git_commit.py.Martin Liska2-2/+6
* gcc-changelog/git_commit.py: Restore print_output syntax in git_commit.py.
2020-05-13Add gcc-changelog related scripts.Martin Liska6-0/+850
* gcc-changelog/git_check_commit.py: New file. * gcc-changelog/git_commit.py: New file. * gcc-changelog/git_email.py: New file. * gcc-changelog/git_repository.py: New file. * gcc-changelog/git_update_version.py: New file.
2020-04-17Do not modify tab options in vimrc for .py files.Martin Liska2-6/+13
* vimrc: We do not want to modify tab options for Python files.
2020-04-16intl: Unbreak intl build with bison 3 when no regeneration is needed [PR92008]Jakub Jelinek2-0/+6
As Iain reported, my change broke the case when one has bison >= 3, but make decides there is no reason to regenerate plural.c, unfortunately that seems to be a scenario I haven't tested. The problem is that the pregenerated plural.c has been generated with bison 1.35, but when config.h says HAVE_BISON3, the code assumes it is the bison3 variant. What used to work fine is when one has bison >= 3 and plural.c has been regenerated (e.g. do touch intl/plural.y and it will work), or when one doesn't have any bison (then nothing is regenerated, but HAVE_BISON3 isn't defined either), or when one has bison < 3 and doesn't need to regenerate, or when one has bison < 3 and it is regenerated. The following patch fixes this, by killing the HAVE_BISON3 macro from config.h, and instead remembering the fact whether plural.c has been created with bison < 3 or bison >= 3 in a separate new plural-config.h header. The way this works: - user doesn't have bison - user has bison >= 3, but intl/{plural-config.h,plural.c} aren't older than intl/plural.y - user has bison < 3, but intl/{plural-config.h,plural.c} aren't older than intl/plural.y pregenerated !USE_BISON3 plural.c and plural-config.h from source dir is used, nothing in the objdir - user has bison >= 3 and intl/plural.y is newer Makefile generates plural.c and USE_BISON3 plural-config.h in the objdir, which is then used in preference to srcdir copies - user has bison < 3 and intl/plural.y is newer Makefile generates plural.c and !USE_BISON3 plural-config.h in the objdir, which is then used in preference to srcdir copies I have tested all these cases and make all-yes worked in all the cases. If one uses the unsupported ./configure where srcdir == objdir, I guess (though haven't tested) that it should still work, just it would be nice if such people didn't try to check in the plural{.c,-config.h} they have regenerated. What doesn't work, but didn't work before either (just tested gcc-9 branch too) is when one doesn't have bison and plural.y is newer than plural.c. Don't do that ;) 2020-04-16 Jakub Jelinek <jakub@redhat.com> PR bootstrap/92008 intl/ * configure.ac: Remove HAVE_BISON3 AC_DEFINE. * Makefile.in (HEADERS): Add plural-config.h. (.y.c): Also create plural-config.h. (dcigettext.o loadmsgcat.o plural.o plural-exp.o): Also depend on plural-config.h. (plural-config.h): Depend on plural.c. * plural-exp.h: Include plural-config.h. Use USE_BISON3 instead of HAVE_BISON3. * plural.y: Use USE_BISON3 instead of HAVE_BISON3. * configure: Regenerated. * plural.c: Regenerated. * config.h.in: Regenerated. * plural-config.h: Generated. contrib/ * gcc_update: Add intl/plural.y dependency for intl/plural-config.h.
2020-04-03Improve svn-rev to search for pattern at line beginning.Martin Liska2-1/+6
* gcc-git-customization.sh: Search for the pattern at line beginning only.
2020-01-24contrib: Change 'remote' for personal branches and add branch creation scriptRichard Earnshaw3-7/+83
Whilst trying to convert the add vendor branch script to work with personal branches I encountered a minor issue where git would report ambiguous refs when checking out the new branch. It turns out that this is because git considers <me>/<topic> to be ambiguous if both refs/heads/<me>/<topic> and refs/remotes/<me>/<topic> exist in the list of known branches. Having thought about this a bit, I think the best solution is to adopt something more like the vendors space and call the remote users/<me> (this also works better if you want to set up remotes to track other users branches as well). So this patch has two parts. 1) It updates gcc-git-customization.sh to set up the new 'remote' and converts any existing remote and branches tracking that to the new format 2) It adds a new script to set up a personal branch on the gcc git repository. * gcc-git-customization.sh: Use users/<pfx> for the personal remote rather than just <pfx>. Convert any existing personal branches to the new remote. * git-add-user-branch.sh: New file.
2020-01-22contrib: script to create a new vendor branchRichard Earnshaw2-0/+52
This script is intended to create a new vendor branch. Doing so is not completely obvious if you are not familiar with the upstream structure, so this takes the pain out of getting it right. It doesn't check out the branch locally, but does set everything up so that, if you have push enabled for your vendor branches, then git push vendors/<vendor> <branch> will work as expected. Run the script as contrib/git-add-vendor-branch.sh <vendor>/<branch> <start-point> the <vendor> space must have previously been set up in the way git-fetch-vendor.sh expects. * git-add-vendor-branch.sh: New file.
2020-01-20contrib: New remotes structure for vendor and personal refsRichard Earnshaw3-25/+105
The initial structure for vendor and personal branches makes use of the default remote (normally origin) for the upstream repository). Unfortunately, this causes some confusion, especially for personal branches because a push will not push to the correct upstream location. This can be 'fixed' by adding a push refspec for the remote, but that has the unfortunate consequence of breaking the push.default behaviour for git push, and it becomes too easy to accidentally commit something unintended to the main parts of the repository. To work around this, this patch changes the configuration to use separate 'remotes' for these additional refs, with one remote for the personal space and another remote for each vendor's space. The personal space is called after the user's preferred branch-space prefix (default 'me'), the vendor spaces are called vendors/<vendor-name>. As far as possible, I've made the script automatically restructure any existing fetch or push lines that earlier versions of the scripts may have created - the gcc-git-customization.sh script will convert all vendor refs that it can find, so it is not necessary to re-add any vendors you've already added. You might, however, want to run git remote prune <origin> after running to clean up any stale upstream-refs that might still be in your local repo, and then git fetch vendors/<vendor> or git fetch <me> to re-populate the remotes/ structures. Also, for any branch you already have that tracks a personal or vendor branch upstream, you might need to run git config branch.<name>.remote <new-remote> so that merges and pushes go to the right place (I haven't attempted to automate this last part). For vendors, the new structure means that git checkout -b <vendor>/<branch> remotes/vendors/<vendor>/<branch> will correctly set up a remote tracking branch. Please be aware that if you have multiple personal branches set up, then git push <me> will still consider all of them for pushing. If you only want to push one branch, then either write git push <me> HEAD or git push <me> <me>/branch as appropriate. And don't forget '-n' (--dry-run) to see what would be done if this were not a dry run. Finally, now that the vendors spaces are isolated from each other and from the other spaces, I've added an option "--enable-push" to git-fetch-vendor.sh. If passed, then a "push" spec will be added for that vendor to enable pushing to the upstream. If you re-run the script for the same vendor without the option, the push spec will be removed. * gcc-git-customization.sh: Check that user-supplied remote name exists before continuting. Use a separate remotes for the personal commit area. Convert existing personal and vendor fetch rules to new layout. * git-fetch-vendor.sh: New vendor layout. Add --enable-push option.
2020-01-17contrib/gcc_update: Insert "tformat:" for git log --pretty=tformat:%p:%t:%HHans-Peter Nilsson2-1/+6
Really old git versions (like 1.6.0) require "git log --pretty=tformat:%p:%t:%H" or else we see: Updating GIT tree Current branch master is up to date. fatal: invalid --pretty format: %p:%t:%H Adjusting file timestamps Touching gcc/config.in... Touching gcc/config/arm/arm-tune.md... ...and an empty revision in LAST_UPDATED and gcc/REVISION. In its absence, for newer git versions, "tformat" is the default qualifier, documented as such default for at least git-2.11.0.
2020-01-16gcc-git-customization.sh: Avoid double expansionAndreas Schwab1-0/+4
2020-01-16gcc-git-customization.sh: avoid double expansionAndreas Schwab1-2/+2
2020-01-16contrib: Check and if needed set user.name and user.email in ↵Richard Earnshaw2-10/+61
gcc-git-customization.sh As discussed on IRC, this adds a couple more checks in the customization setup for git. If the variables user.name and user.email are not set anywhere in the git config hierarchy, we set some local values. We always ask about the values we detect and if the user gives an answer that is new, we save that in the local config: this gives the opportunity to use different values to those configured for the global space. Also cleaned up a couple of minor niggles, such as using $(cmd) rather than `cmd` for subshells and some quoting issues when using eval. * gcc-git-customization.sh: Check that user.name and user.email are set. Use $(cmd) instead of `cmd`. Fix variable quoting when using eval.
2020-01-16contrib: Verify the id to be printed is ancestor of the corresponding remote ↵Jakub Jelinek2-1/+7
release branch (or master), otherwise print nothing. The monotonically increasing revision ids need to be globally unique, so they should only identify commits that were committed to the upstream repo to its master or releases/gcc-N branches. The alias could print something even for private branches or vendor branches etc., but if such an identifier is then used publicly, it will refer to something else. 2020-01-16 Jakub Jelinek <jakub@redhat.com> * gcc-git-customization.sh: Verify the id to be printed is ancestor of the corresponding remote release branch (or master), otherwise print nothing.
2020-01-15Add *.md diff=md.Jakub Jelinek2-1/+6
2020-01-15 Segher Boessenkool <segher@kernel.crashing.org> Jakub Jelinek <jakub@redhat.com> * .gitattributes: Add *.md diff=md. contrib/ * gcc-git-customization.sh: Change uses to use in comment.
2020-01-15Handle output of older git in gcc-descr and gcc-undescr aliases.Jakub Jelinek2-2/+7
2020-01-15contrib: Don't add push rules for personal and vendor spaces.Richard Earnshaw3-4/+24
Originally, it seemed like a good idea to add automatic 'push' rules to the git configuration, so that personal- and vendor-space commits would automatically push to the right place. Unfortunately, this changes git's behaviour and with these settings "git push" will try to push all branches in a local tree up to the corresponding location on the server (ignoring the push.default setting). The only known mitigation for this is to ALWAYS use "git push <server> <branch>". So instead, we no-longer add those rules by default and will document the options on the wiki. We don't automatically remove the push entries but do print out the command that will do so, if the user so wishes. * gcc-git-customization.sh: Explain why we want the user's upstream account name. Don't add push rules. Check if push rules have been added and suggest that they should be removed. * git-fetch-vendor.sh: Don't add push rules.
2020-01-14The mentioned auto-generated file is no more part of theGeorg-Johann Lay1-1/+0
GCC sources, it's auto-generated in $(builddir) during build. PR target/92055 * contrib/gcc_update (files_and_dependencies): Remove entry for gcc/config/avr/t-multilib.
2020-01-13Revert "contrib: Add in the default push rule which was overridden"Richard Earnshaw3-11/+12
This reverts commit b60563a8bf18b5a49431b5913f32f5c5ff8319d9. Doesn't work as expected.
2020-01-13contrib: Add in the default push rule which was overriddenRichard Earnshaw3-3/+17
When we add a push rule, the default rule gets removed, so add that in explicitly. This needs to come last since otherwise it would match the custom redirecting rules we have for personal and vendor sub-spaces. I also noticed that the push rule for the vendor subspace still had a force push default. We don't want that so remove it. * gcc-git-customization.sh: Add back the default rule that is lost by adding a custom push rule. * git-fetch-vendor.sh: Likewise, also remove '+' from push specs.
2020-01-13contrib: script to setup git to pull a vendors branchesRichard Earnshaw2-0/+26
This simple script is intended to setup a new git configuration to pull the branches and tags for a specific vendor. This should simplify some of the steps needed for working with a vendor's branches. * git-fetch-vendor.sh: New file.
2020-01-13contrib: Add git gcc-descr and gcc-undescr aliases.Jakub Jelinek2-0/+10
2020-01-13 Jakub Jelinek <jakub@redhat.com> * contrib/gcc-git-customization.sh: Add git gcc-descr and gcc-undescr aliases.
2020-01-13contrib: Add script to help with customizing a git checkout for use with GCCRichard Earnshaw2-0/+73
This patch is intended to help with folks setting up a git work environment for use with GCC following the transition to git. It currently does a couple of things. 1) Add an alias 'svn-rev' to git so that you can look up a legacy commit by its svn revision number. This enables you to type git svn-rev 1234 and git will show the commit log entry relating to SVN r1234. 2) Sets up tracking information for the user's personal area in the git repo. It tries to figure out some sensible answers to the data it needs, but allows the user to override the values. It then creates the fetch and push entries that are needed for tracking the extra refs. This implements one part of the recommendations that I've proposed in svnwrite.html for dealing with private branches. It should be possible to run the script more than once and for it to DTRT. If you change your answers the configuration should be correctly updated. 2020-01-13 Richard Earnshaw <rearnsha@arm.com> * gcc-git-customization: New file.
2020-01-01update-copyright.py: Add Mentor Graphics Corporation and Yoshinori Sato as ↵Jakub Jelinek2-1/+9
external authors. * update-copyright.py: Add Mentor Graphics Corporation and Yoshinori Sato as external authors. Skip LICENSE.txt files. From-SVN: r279812
2019-12-16MSP430: Add new msp430-elfbare targetJozef Lawrynowicz2-1/+5
contrib/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config-list.mk: Add msp430-elfbare. gcc/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config.gcc: s/msp430*-*-*/msp430-*-*. Handle msp430-*-elfbare. * config/msp430/msp430-devices.c (TARGET_SUBDIR): Define. (_MSPMKSTR): Define. (__MSPMKSTR): Define. (rest_of_devices_path): Use TARGET_SUBDIR value in string. * config/msp430/msp430.c (msp430_option_override): Error if -fuse-cxa-atexit is used when it has been disabled at configure time. * config/msp430/t-msp430: Define TARGET_SUBDIR when building msp430-devices.o. * doc/install.texi: Document msp430-*-elf and msp430-*-elfbare. * doc/invoke.texi: Update documentation about which path devices.csv is searched for. gcc/testsuite/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * g++.dg/init/dso_handle1.C: Require cxa_atexit support. * g++.dg/init/dso_handle2.C: Likewise. * g++.dg/other/cxa-atexit1.C: Likewise. * gcc.target/msp430/msp430.exp: Update csv-using-installed.c test to handle msp430-elfbare configuration. libgcc/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config.host: s/msp430*-*-elf/msp430-*-elf*. Override default "extra_parts" variable. * configure: Regenerate. * configure.ac: Disable TM clone registry by default for msp430-elfbare. From-SVN: r279442
2019-12-09Byte vs column awareness for diagnostic-show-locus.c (PR 49973)Lewis Hyatt9-0/+38087
contrib/ChangeLog 2019-12-09 Lewis Hyatt <lhyatt@gmail.com> PR preprocessor/49973 * unicode/from_glibc/unicode_utils.py: Support script from glibc (commit 464cd3) to extract character widths from Unicode data files. * unicode/from_glibc/utf8_gen.py: Likewise. * unicode/UnicodeData.txt: Unicode v. 12.1.0 data file. * unicode/EastAsianWidth.txt: Likewise. * unicode/PropList.txt: Likewise. * unicode/gen_wcwidth.py: New utility to generate libcpp/generated_cpp_wcwidth.h with help from the glibc support scripts and the Unicode data files. * unicode/unicode-license.txt: Added. * unicode/README: New explanatory file. libcpp/ChangeLog 2019-12-09 Lewis Hyatt <lhyatt@gmail.com> PR preprocessor/49973 * generated_cpp_wcwidth.h: New file generated by ../contrib/unicode/gen_wcwidth.py, supports new cpp_wcwidth function. * charset.c (compute_next_display_width): New function to help implement display columns. (cpp_byte_column_to_display_column): Likewise. (cpp_display_column_to_byte_column): Likewise. (cpp_wcwidth): Likewise. * include/cpplib.h (cpp_byte_column_to_display_column): Declare. (cpp_display_column_to_byte_column): Declare. (cpp_wcwidth): Declare. (cpp_display_width): New function. gcc/ChangeLog 2019-12-09 Lewis Hyatt <lhyatt@gmail.com> PR preprocessor/49973 * input.c (location_compute_display_column): New function to help with multibyte awareness in diagnostics. (test_cpp_utf8): New self-test. (input_c_tests): Call the new test. * input.h (location_compute_display_column): Declare. * diagnostic-show-locus.c: Pervasive changes to add multibyte awareness to all classes and functions. (enum column_unit): New enum. (class exploc_with_display_col): New class. (class layout_point): Convert m_column member to array m_columns[2]. (layout_range::contains_point): Add col_unit argument. (test_layout_range_for_single_point): Pass new argument. (test_layout_range_for_single_line): Likewise. (test_layout_range_for_multiple_lines): Likewise. (line_bounds::convert_to_display_cols): New function. (layout::get_state_at_point): Add col_unit argument. (make_range): Use empty filename rather than dummy filename. (get_line_width_without_trailing_whitespace): Rename to... (get_line_bytes_without_trailing_whitespace): ...this. (test_get_line_width_without_trailing_whitespace): Rename to... (test_get_line_bytes_without_trailing_whitespace): ...this. (class layout): m_exploc changed to exploc_with_display_col from plain expanded_location. (layout::get_linenum_width): New accessor member function. (layout::get_x_offset_display): Likewise. (layout::calculate_linenum_width): New subroutine for the constuctor. (layout::calculate_x_offset_display): Likewise. (layout::layout): Use the new subroutines. Add multibyte awareness. (layout::print_source_line): Add multibyte awareness. (layout::print_line): Likewise. (layout::print_annotation_line): Likewise. (line_label::line_label): Likewise. (layout::print_any_labels): Likewise. (layout::annotation_line_showed_range_p): Likewise. (get_printed_columns): Likewise. (class line_label): Rename m_length to m_display_width. (get_affected_columns): Rename to... (get_affected_range): ...this; add col_unit argument and multibyte awareness. (class correction): Add m_affected_bytes and m_display_cols members. Rename m_len to m_byte_length for clarity. Add multibyte awareness throughout. (correction::insertion_p): Add multibyte awareness. (correction::compute_display_cols): New function. (correction::ensure_terminated): Use new member name m_byte_length. (line_corrections::add_hint): Add multibyte awareness. (layout::print_trailing_fixits): Likewise. (layout::get_x_bound_for_row): Likewise. (test_one_liner_simple_caret_utf8): New self-test analogous to the one with _utf8 suffix removed, testing multibyte awareness. (test_one_liner_caret_and_range_utf8): Likewise. (test_one_liner_multiple_carets_and_ranges_utf8): Likewise. (test_one_liner_fixit_insert_before_utf8): Likewise. (test_one_liner_fixit_insert_after_utf8): Likewise. (test_one_liner_fixit_remove_utf8): Likewise. (test_one_liner_fixit_replace_utf8): Likewise. (test_one_liner_fixit_replace_non_equal_range_utf8): Likewise. (test_one_liner_fixit_replace_equal_secondary_range_utf8): Likewise. (test_one_liner_fixit_validation_adhoc_locations_utf8): Likewise. (test_one_liner_many_fixits_1_utf8): Likewise. (test_one_liner_many_fixits_2_utf8): Likewise. (test_one_liner_labels_utf8): Likewise. (test_diagnostic_show_locus_one_liner_utf8): Likewise. (test_overlapped_fixit_printing_utf8): Likewise. (test_overlapped_fixit_printing): Adapt for changes to get_affected_columns, get_printed_columns and class corrections. (test_overlapped_fixit_printing_2): Likewise. (test_linenum_sep): New constant. (test_left_margin): Likewise. (test_offset_impl): Helper function for new test. (test_layout_x_offset_display_utf8): New test. (diagnostic_show_locus_c_tests): Call new tests. gcc/testsuite/ChangeLog: 2019-12-09 Lewis Hyatt <lhyatt@gmail.com> PR preprocessor/49973 * gcc.dg/plugin/diagnostic_plugin_test_show_locus.c (test_show_locus): Tweak so that expected output is the same as before the diagnostic-show-locus.c changes. * gcc.dg/cpp/pr66415-1.c: Likewise. From-SVN: r279137
2019-12-07Fix @multitable handling in texi2pod.plRichard Sandiford2-2/+12
While trying out Dennis's Armv8.6-A patch, I noticed that texi2pod.pl didn't handle the new @multitable correctly. There were two problems: (1) @multitables nested in other @tables inherited the @item type from the enclosing @table. Since the new @multitable is in a @table @samp, we applied @samp markup to the @multitable @items. This in turn meant that it captured the @tab separator in the @item markup. Fixed by pushing an empty item code onto the stack. (2) We didn't handle @headitem. Fixed by enclosing it in italics, like we do for section headings. This causes it to be underlined in the man output. 2019-12-07 Richard Sandiford <richard.sandiford@arm.com> contrib/ * texi2pod.pl: Handle @headitems in @multitables, printing them in italics. Push an empty item code onto the stack. From-SVN: r279074
2019-11-13download_prerequisites: Use http instead of ftp for downloading.Janne Blomqvist2-2/+6
2019-11-13 Janne Blomqvist <jb@gcc.gnu.org> * download_prerequisites: Use http instead of ftp for downloading. From-SVN: r278151