Re: Mixing OO and DB

From: Tegiri Nenashi <TegiriNenashi_at_gmail.com>
Date: Thu, 14 Feb 2008 12:47:31 -0800 (PST)
Message-ID: <aa2f2545-bcd7-43db-9e3f-c781afe6eb78_at_u10g2000prn.googlegroups.com>


On Feb 14, 12:20 pm, "Dmitry A. Kazakov" <mail..._at_dmitry-kazakov.de> wrote:
> On Thu, 14 Feb 2008 10:02:11 -0800 (PST), Tegiri Nenashi wrote:
> > Please note that formal grammars are declarative specifications of the
> > data which are serialized as strings of characters. Ideally, the
> > grammar solution should be as clean as the database one. In practice,
> > however, there are silly limitations -- you have to check that your
> > grammar conforms to a specific "vision" of the compiler designer. For
> > example, ANTLR goes only as far as LL(*) and chokes on ambiguous
> > grammars. Contrast this to DBMS world where RDBMS executes the query
> > no matter how badly it is written.
>
> LOL. Like letting a DFA to recognize a^n b^n... You made my day, thanks!

On Feb 14, 12:20 pm, "Dmitry A. Kazakov" <mail..._at_dmitry-kazakov.de> wrote:
> On Thu, 14 Feb 2008 10:02:11 -0800 (PST), Tegiri Nenashi wrote:
> > Please note that formal grammars are declarative specifications of the
> > data which are serialized as strings of characters. Ideally, the
> > grammar solution should be as clean as the database one. In practice,
> > however, there are silly limitations -- you have to check that your
> > grammar conforms to a specific "vision" of the compiler designer. For
> > example, ANTLR goes only as far as LL(*) and chokes on ambiguous
> > grammars. Contrast this to DBMS world where RDBMS executes the query
> > no matter how badly it is written.
>
> LOL. Like letting a DFA to recognize a^n b^n... You made my day, thanks!

I'm glad I entertained you, although you are missing the point (as usual). What languages on a particular levels of Chomsky hierarcky are capable (or rather uncapable of) is not important. Grammar based methods are immature (yet?) and there is even no clear concept of string transformation. Attribute grammars is as far as the theory got, but in practice people put all kind of horrible procedural sideeffects inside the curly brakets after each grammar rule.

BTW, I was talking about CFGs which have nothing to do with NFA or DFA. Also, one of the things that makes the grammar field unaccessible to mainstream programmers is the concept of automata itself! Automaton is just a particular (and not very natural) regular language representation. Then, you have all sorts of automata derived constructions (e.g. stack machines) -- give me a break. Received on Thu Feb 14 2008 - 21:47:31 CET

Original text of this message