Re: parser using perl



Chas. Owens wrote:

In general, it doesn't matter if you want to work with a small piece
of a language or the whole language, you still need to implement a
parser for the whole language. You can get an eighty or ninety
percent solution without a full parser, but there will always be
problems.

That's not true at all. A file containing

int i;

is a valid C file. If the input expected by the OP contains a subset of
the C syntax then it can be parsed as such. C is s subset of C++. Does
that mean that everybody suddenly needs a C++ compiler to compile their
C programs? I think not.

Rob
.



Relevant Pages

  • Re: Some clarification on "Pre-Parsers" and other bits
    ... the "C" you are talking about is a language. ... would be confusing) that is a parser for the C language. ... A typical compiler ... the input is syntactically correct. ...
    (alt.lang.asm)
  • Re: "STL from the Ground Up"
    ... high-level intermediate language than can interoperate with many other ... If your language lacks expressive features then you cannot write code ... memory management in comparison. ... Mostly because type errors mean that the programmer and compiler disagree ...
    (comp.programming)
  • Re: A note on computing thugs and coding bums
    ... It would handle international characters if the execution character ... method I used in "Build Your Own .Net Language and Compiler". ... work areas and counting on Nul is an illusion. ...
    (comp.programming)
  • Re: WaitForSingleObject() will not deadlock
    ... represent an incorrect implementation of the language. ... the *compiler* does not guarantee this. ... but to state it in terms of the execution instead of the formal semantics of the language ... as long as the optimizations do not change the semantics of the language). ...
    (microsoft.public.vc.mfc)
  • Re: ISA-independent programming language
    ... the compiler takes care of it. ... >> or two representations for zero should not matter to me. ... Any language is a "CLOSED ENVIRONMENT." ...
    (comp.arch)