in reply to No, it is not
in thread Is this code correct

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re^2: No, it is not
by andye (Curate) on Jan 28, 2009 at 16:51 UTC
    Then no, it's not correct.

    The brackets don't match.

    Try putting use diagnostics; at the start of your script, if you're having trouble understanding Perl's error messages. This will make the error messages more 'explainy'.

Re^2: No, it is not
by kennethk (Abbot) on Jan 28, 2009 at 16:51 UTC
    This error means that your file has an unbalanced set of brackets. The code you posted is fine in this regard. Might I suggest making a copy of main.pl and systematically deleting subroutines from the tail of the file until this error goes away, thus identifying the guilty party?
      The code you posted is fine in this regard.

      Actually, it isn't. The OP's inconsistent indenting is hiding problems in this respect.

      update: doh - my eyes crossed due to the terrible layout. sorry, no, the code above does have matching brackets. evidently this problem is elsewhere.