Thanks Mary and Rick for the long answer. I wish NCL had a End of Line
character like C & Perl, and braces for nesting statements. Is it too
hard to change or will it now be too late to make such a change?
I am confused when I dont see braces or some sort of nesting delimiter.
Indentation doesn't seem natural without braces. I may sound radical
--- Rick Grubin <grubin AT ucar.edu> wrote:
> On Fri, 25 Apr 2003, Amit Kulkarni wrote:
> > why does NCL spit out this when there is no newline after the 'end'
> > statement at the end of file? Is this by design?
> > Thanks!
> > fatal:syntax error: line -1 before or near
> > end
> > ---^
> > fatal:error in statement
> Hi Amit,
> NCL script code must be parsed to ensure that the script syntax is
> and contains no errors, e.g. there must be an "end do" for each "do"
> Part of NCL's syntax is that a "statement" in NCL has no specific
> terminating character, like C's and Perl's ";" character. NCL's
> looks for an end-of-line character (a carriage return/newline
> as it's statement (and line) termination. Without this termination
> character for a statement, NCL's parser deduces that the statement in
> question is incomplete, and emits the error you're seeing.
> The short answer: each NCL statement requires a newline to properly
> terminate it, in a syntactical sense.
> Rick Grubin Visualization + Enabling Technologies
> Scientific Computing Division National Center for Atmospheric
> grubin AT ncar.ucar.edu 303.497.1832
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo
ncl-talk mailing list
ncl-talk AT ucar.edu
This archive was generated by hypermail 2b29 : Fri Apr 25 2003 - 13:10:27 MDT