in reply to Re: Extract attributes/values from XML using perl
in thread Extract attributes/values from XML using perl / declaring wires in verilog using perl

I'm currently using the perl version 5.8.8 and "feature" is in perl 5.10 if I'm not wrong. Anyway to surpass this hurdle?. Since the upgrade is in the admins hand and that is not happening anytime soon, was hoping something can be done

  • Comment on Re^2: Extract attributes/values from XML using perl

Replies are listed 'Best First'.
Re^3: Extract attributes/values from XML using perl
by choroba (Cardinal) on Jan 08, 2016 at 06:46 UTC
    It's not relevant to the problem. Use print instead of say and add a newline.
    ($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,
Re^3: Extract attributes/values from XML using perl
by 1nickt (Canon) on Jan 08, 2016 at 07:38 UTC

    Agree with choroba's post that you don't need the feature 'say' to solve your issue. But FYI, in Perl you can create your own global functions with the core module Exporter. A very naive implementation:

    In MyFeatures.pm:

    package MyFeatures; use strict; use warnings; use Exporter qw/ import /; our @EXPORT_OK = qw/ say /; sub say { my $str = shift; print "$str\n"; } 1; # return true

    In your program:

    #!/usr/bin/perl use strict; use warnings; use MyFeatures qw/ say /; my $str = 'Hello, world.'; say $str; say q{Nice weather, isn't it?}; __END__

    Output:

    Hello, world. Nice weather, isn't it?

    Hope this helps.

    The way forward always starts with a minimal test.

      That's useful, Thank you