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

continue scanning one-liners when use if, autouse or >5.010 found #2

Merged
merged 2 commits into from Jul 3, 2017

Conversation

shawnlaffan
Copy link
Contributor

scan_line was returning early and ignoring %found as soon as it encountered a line containing "use 5.010" (anything greater than v5.9.5), "use if" or "use autouse".

This meant it returned only feature.pm for one-liners such as "use 5.024; use Some::Other::Module". Similar issues occurred for the if and autouse pragmas.

There is still an early return when the package keyword is found. I'm not sure of the best way to handle that, though, as it sets a global $CurrentPackage so I assume it has knock-on effects. One also expects it to be uncommon in one-liners in the wild.

Previously the system returned feature.pm and ignored thre rest of the line.
Also update test descriptions for previous commit
@rschupp rschupp merged commit 06ae53f into rschupp:master Jul 3, 2017
@rschupp
Copy link
Owner

rschupp commented Jul 3, 2017

Thanks, Shawn

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.

None yet

2 participants