Parser regression: valid multi-component package declaration fails in AI::Prolog
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 72/100
Research direction
Start by examining commit 95b8824a9 and the package declaration parsing path, then reproduce the failure with t/35clause.t and t/50engine.t. Add project-owned coverage for a valid multi-component package declaration and verify that both the JVM and interpreter backends pass the focused tests without the misleading diagnostic.
Written by the indexing model from the issue text.
Description
Summary
AI::Prolog 0.741 has a regression under PerlOnJava when loading AI::Prolog::TermList::Clause.
Reproduction
CPAN random tester run: 20260916-111623-23683
Affected upstream tests:
t/35clause.tt/50engine.t
Both fail on the JVM backend and the interpreter backend. The first failure is:
Failed test 'use AI::Prolog::TermList::Clause;'
Error: package operator requires an identifier at ../lib/AI/Prolog/TermList/Clause.pm line 1, near ";"
The source begins with the valid declaration:
package AI::Prolog::TermList::Clause;
The same parser failure then prevents AI::Prolog::Engine from loading in t/50engine.t.
Expected result
Under system Perl, with the exact dependency versions selected by the CPAN run, both focused tests pass: 49 tests successful.
Actual result
PerlOnJava reports 2 of 19 test programs failing, with 2 of 414 subtests failed overall. The regression is recorded against the previous passing run from 2026-08-28.
Suspected cause
The regression appears to have been introduced by commit 95b8824a9 (fix: validate package version declarations), which added validatePackageVersion(parser) to package declaration parsing. A valid multi-component package declaration is being compiled with a non-identifier operand, producing the misleading package operator requires an identifier diagnostic.
This should be reduced to project-owned parser regression coverage for a valid multi-component package declaration, then verified on both execution backends.
The full system-Perl distribution suite was not completed because the local environment lacks the transitive prerequisite Carp::Assert; this does not affect the focused system-Perl comparison above.
- Dominant language
- Perl
- Stars
- 64
- Forks
- 6
- Avg merge
- 5h 25m
- Merged PRs (30d)
- 157
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from fglock/PerlOnJava
-
area:cpan-port area:unicode bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
fglock/PerlOnJava#1341 ·
-
area:cpan-port bug
Difficulty 4/5 3-5 days Newbie friendliness 44/100
fglock/PerlOnJava#1459 ·
-
area:cpan-port bug
Difficulty 3/5 1-2 days Newbie friendliness 72/100
fglock/PerlOnJava#1457 ·
-
bug high-impact
Difficulty 3/5 1-2 days Newbie friendliness 67/100
fglock/PerlOnJava#1456 · 1 comment ·
-
bug
Difficulty 4/5 3-5 days Newbie friendliness 72/100
fglock/PerlOnJava#1455 ·
All issues in fglock/PerlOnJava
Similar issues
-
1.severity: security
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
api7/lua-resty-saml#63 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 68/100
-
Difficulty 1/5 Under an hour Newbie friendliness 82/100
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100