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

patch: throw() regression #944

Merged
merged 1 commit into from
Feb 7, 2025
Merged

Conversation

mknos
Copy link
Contributor

@mknos mknos commented Feb 7, 2025

  • I noticed a runtime error within Patch::Ed::apply() where the throw function can't be resolved
  • This error didn't happen when I switch back to historical commit 8a1ef6a
  • The Patch::import() function had been removed, and this was forcibly putting throw into the caller's namespace
  • None of the other subclasses of Patch call throw(), only Patch::Ed does
  • The old import() approach was not the Right Thing so I don't want to revert to it
  • Make throw() an oo method instead of a simple function; this allows perl to resolve it from the parent class
  • Delete an incorrect comment that origfile comes from -o option (-o is output and origfile is input)
%perl patch -u a.c patch.ed
Not a unified diff!
Skipping patch...
Undefined subroutine &Patch::Ed::throw called at patch line 901, <$fh> line 208.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
* I noticed a runtime error within Patch::Ed::apply() where the throw function can't be resolved
* This error didn't happen when I switch back to historical commit 8a1ef6a
* The Patch::import() function had been removed, and this was forcibly putting throw into the caller's namespace
* None of the other subclasses of Patch call throw(), only Patch::Ed does
* The old import() approach was not the Right Thing so I don't want to revert to it
* Make throw() an oo method instead of a simple function; this allows perl to resolve it from the parent class
@github-actions github-actions bot added Type: enhancement improve a feature that already exists Priority: low get to this whenever Program: patch The patch program labels Feb 7, 2025
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@mknos mknos temporarily deployed to automated_testing February 7, 2025 01:33 — with GitHub Actions Inactive
@briandfoy briandfoy merged commit 493a57e into briandfoy:master Feb 7, 2025
23 checks passed
@briandfoy
Copy link
Owner

changes: fix the unresolvable throw() encountered when skipping a patch

@briandfoy briandfoy self-assigned this Feb 7, 2025
@briandfoy briandfoy added Status: accepted The fix is accepted and removed Priority: low get to this whenever labels Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Program: patch The patch program Status: accepted The fix is accepted Type: enhancement improve a feature that already exists
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants