Skip to content

fix: recognize retired experimental::isa warning category #1164

Description

@fglock

Summary

PerlOnJava rejects the retired compatibility warning category
experimental::isa, so otherwise portable code that silences the warning from
older Perls cannot compile.

Reproducer

use feature 'isa';
no warnings 'experimental::isa';

my $obj = bless {}, 'Foo';
print "ok\n" if $obj isa Foo;

Expected behavior

Perl 5.42 accepts the retired category and prints ok. The isa feature is
stable, but the old warning category remains recognized for source
compatibility.

Actual behavior

Both the JVM and interpreter backends fail at compile time:

Unknown warnings category 'experimental::isa'

with exit status 255.

Investigation notes

The Java warning registry already deliberately retains several retired
compatibility aliases, including experimental::signatures,
experimental::postderef, and experimental::lexical_subs; those were
verified to work on both backends. experimental::isa is missing from the
registry and warning hierarchy. experimental::alpha_assertions is another
category accepted by Perl 5.42 but currently rejected by PerlOnJava, suggesting
the compatibility alias set needs an audit against the target Perl version.

Impact

This is a source-compatibility blocker for modules written while isa was
experimental (Perl 5.32--5.38), where guarding the warning is a normal
cross-version idiom. It fails before application code can run.

Acceptance criteria

  • no warnings 'experimental::isa' is accepted as a no-op compatibility
    category on both backends.
  • use warnings 'experimental::isa' and warnings category queries remain
    internally consistent.
  • Audit other retired categories retained by supported Perl versions; include
    at least experimental::alpha_assertions where Perl still accepts it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions