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

parser-state: fix attribute merging (backport #11294) #12209

Open
wants to merge 1 commit into
base: 2.24-maintenance
Choose a base branch
from

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jan 10, 2025

Motivation

Fixes #11268.

Context

This should be non-breaking. As a side effect, it makes some duplicate attribute error messages nicer (later occurrences point back to previous occurrences rather than the other way around).

I'm working at the edge of my proficiency with C++ here, so please take extra care to verify that how I'm handling pointers and memory management is sensible, because I'm not confident that I'm doing it right.

Priorities and Process

Add 👍 to pull requests you find important.

The Nix maintainer team uses a GitHub project board to schedule and track reviews.


This is an automatic backport of pull request #11294 done by [Mergify](https://mergify.com).

(cherry picked from commit 8034589)

# Conflicts:
#	src/libexpr/parser-state.hh
Copy link
Contributor Author

mergify bot commented Jan 10, 2025

Cherry-pick of 8034589 has failed:

On branch mergify/bp/2.24-maintenance/pr-11294
Your branch is up to date with 'origin/2.24-maintenance'.

You are currently cherry-picking commit 8034589d7.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	new file:   tests/functional/lang/eval-fail-attrset-merge-drops-later-rec.err.exp
	new file:   tests/functional/lang/eval-fail-attrset-merge-drops-later-rec.nix
	new file:   tests/functional/lang/eval-okay-regrettable-rec-attrset-merge.exp
	new file:   tests/functional/lang/eval-okay-regrettable-rec-attrset-merge.nix
	modified:   tests/functional/lang/parse-fail-mixed-nested-attrs1.err.exp
	modified:   tests/functional/lang/parse-fail-mixed-nested-attrs2.err.exp
	modified:   tests/unit/libexpr/trivial.cc

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   src/libexpr/parser-state.hh

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@mergify mergify bot requested a review from edolstra as a code owner January 10, 2025 10:40
@github-actions github-actions bot added the with-tests Issues related to testing. PRs with tests have some priority label Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conflicts merge-queue with-tests Issues related to testing. PRs with tests have some priority
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant