Thanks to visit codestin.com
Credit goes to github.com

Skip to content

NiceSlice code with dubious "=over" fails in 2.080 #406

@fantasma13

Description

@fantasma13

HI Ed,
make test fails with NiceSlice errors, so do a lot of programs. Both latest git as from CPAN.
2.079 still works.
Is this maybe related to Text-Balanced? Installed version is 2.06. Debian linux.

Here's a quite minimal example. I think it has to do with ( ) or {} in comments.

PDL 2.080: perl -Mblib -e "use test_ns; "

syntax error at /home/ingo/perl/test_ns.pm line 24, near "$iii("
Compilation failed in require at -e line 1.
BEGIN failed--compilation aborted at -e line 1.

PDL 2.079: perl -Mblib -e "use test_ns; "

syntax error at /home/ingo/perl/test_ns.pm line 24, near "$iii("
Compilation failed in require at -e line 1.
BEGIN failed--compilation aborted at -e line 1.

test_ns.pm:

#!/usr/bin/perl  

package test_ns;
use PDL;
use PDL::NiceSlice;

=over
sub fmod {
        my $x=shift;
        my $y=shift; 
        my $n=floor $x/$y; 
        return $x-$n*$y;
}


sub amp {
        my $i=shift; 
        return (sqrt($i((0),)**2+$i((1),)**2));
}
=cut

sub phase {
        my $iii=shift;
        return (atan2($iii((1),),$iii((0),)));
}

# { 
# #} sMDH;                                        // total length: 32 * 32 Bit (128 Byte)            128
#

1;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions