RE: Missing Bracket
I would guess that you are missing a curly bracket '}' somewhere in your program, but the program doesn't realize it until the end. The only way to find it that I know of is to use good spacing in your program and walk through { by { looking to make sure that it's paired correctly. /\/\ark -Original Message- From: Balint, Jess [mailto:JBalint;alldata.net] Sent: Tuesday, October 22, 2002 11:17 AM To: '[EMAIL PROTECTED]' Subject: Missing Bracket Hi all. I am sorry to post a question such stupid as this one, but it has me stumped. I have a fairly long perl program that gives me the following error when I run it. Missing right bracket at ./a.pl line 877, at end of line syntax error at ./a.pl line 877, at EOF Execution of ./a.pl aborted due to compilation errors. I am assuming the bracket is the square bracket (]). 877 is the last line of my program and I can't seem to find anywhere that I am missing a right bracket. Is there an sure-fire way to figure it out? Thanks. jess -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Missing Bracket
See inline comment: -Original Message- From: Balint, Jess [mailto:JBalint;alldata.net] Sent: Tuesday, October 22, 2002 2:17 PM To: '[EMAIL PROTECTED]' Subject: Missing Bracket Hi all. I am sorry to post a question such stupid as this one, but it has me stumped. I have a fairly long perl program that gives me the following error when I run it. Missing right bracket at ./a.pl line 877, at end of line syntax error at ./a.pl line 877, at EOF Execution of ./a.pl aborted due to compilation errors. I am assuming the bracket is the square bracket (]). 877 is Don't assume its a square bracket. It's probably a curly (}). the last line of my program and I can't seem to find anywhere that I am missing a right bracket. Is there an sure-fire way to figure it out? Thanks. jess -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] The views and opinions expressed in this email message are the sender's own, and do not necessarily represent the views and opinions of Summit Systems Inc. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Missing Bracket
If you have no '{}'s in mid-line comments, you could - #!/usr/bin/perl -w use strict; my ($open, $close) = (0,0); while( ) { $open += () = $_ =~ m'{'g unless /^#/;; $close += () = $_ =~ m'}'g unless /^#/; } print Opens: $open\nCloses: $close\n; # bracket_check.pl filename -G On Tue, 22 Oct 2002 14:17:28 -0400 Balint, Jess [EMAIL PROTECTED] wrote: Hi all. I am sorry to post a question such stupid as this one, but it has me stumped. I have a fairly long perl program that gives me the following error when I run it. Missing right bracket at ./a.pl line 877, at end of line syntax error at ./a.pl line 877, at EOF Execution of ./a.pl aborted due to compilation errors. I am assuming the bracket is the square bracket (]). 877 is the last line of my program and I can't seem to find anywhere that I am missing a right bracket. Is there an sure-fire way to figure it out? Thanks. jess -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]