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

mkString fixes (mostly moved from the multi-decl overhaul) #714

Merged
merged 8 commits into from
Oct 6, 2021

Commits on Sep 28, 2021

  1. mkString fixes that were previously part of the multi-decl overhaul.

    Back when the multi-decl overhaul
    (#657) switched
    all unchanged multi-decl members from Decl::print to mkString, these
    fixes were needed to prevent 3C's output from getting worse on some
    unchanged multi-decl members in the regression tests. The fixes are no
    longer needed for that reason, but Mike still asked me to submit them.
    They do benefit some more complex cases that occur in the regression
    tests, so the updates to the expected output of those tests provide test
    coverage for the fixes.
    mattmccutchen-cci committed Sep 28, 2021
    Configuration menu
    Copy the full SHA
    d4923e2 View commit details
    Browse the repository at this point in the history
  2. Bonus fix: Avoid an extra space after a return type ending in *.

    I'm including this because the code fix was similar to a fix that was
    originally in the multi-decl overhaul before the same fix was needed in
    #702 and I was
    aware of the issue from item 4 of
    #703.
    mattmccutchen-cci committed Sep 28, 2021
    Configuration menu
    Copy the full SHA
    6d3c495 View commit details
    Browse the repository at this point in the history

Commits on Sep 29, 2021

  1. Configuration menu
    Copy the full SHA
    1ce3450 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    59da4ff View commit details
    Browse the repository at this point in the history

Commits on Oct 1, 2021

  1. mkString simplifications.

    As I dug into the reasons why all the conditionals in the PR so far were
    needed under the current design of the rest of mkString, I realized that
    the design could be straightened out a bit and correctly handle one more
    case involving checked pointers to fixed-size arrays. This doesn't
    address the more difficult problems with wild pointers to fixed-size
    arrays or with wild pointer levels being in reverse order in general
    (see #703).
    mattmccutchen-cci committed Oct 1, 2021
    Configuration menu
    Copy the full SHA
    2c5e8ac View commit details
    Browse the repository at this point in the history

Commits on Oct 2, 2021

  1. Fix checked pointers to arrays of wild function pointers.

    Any array levels still pending when we reach a function pointer should
    become part of the function pointer declarator even if some text for an
    outer checked pointer level has already been added to Ss. However, any
    array levels that are outside the checked pointer level and have already
    been committed to EndStrs should remain at the end of the entire type
    and not get sucked into the function pointer declarator. To maintain
    this distinction, we need to use a separate `FptrEndStrs` list for the
    array levels in the function pointer declarator.
    mattmccutchen-cci committed Oct 2, 2021
    Configuration menu
    Copy the full SHA
    34b4a54 View commit details
    Browse the repository at this point in the history
  2. Address John's review comments.

    Also update a link to go to an existing issue John pointed out.
    mattmccutchen-cci committed Oct 2, 2021
    Configuration menu
    Copy the full SHA
    4a04607 View commit details
    Browse the repository at this point in the history

Commits on Oct 5, 2021

  1. Configuration menu
    Copy the full SHA
    b8c3729 View commit details
    Browse the repository at this point in the history