Re: Going backwards from a Language(or set of expressions) to a Grammar

Stefan Monnier <monnier@iro.umontreal.ca>
Sat, 06 May 2017 22:02:16 -0400

          From comp.compilers

Related articles
Going backwards from a Language(or set of expressions) to a Grammar seimarao@gmail.com (Seima Rao) (2017-04-16)
Re: Going backwards from a Language(or set of expressions) to a Gramma seimarao@gmail.com (Seima Rao) (2017-04-17)
Re: Going backwards from a Language(or set of expressions) to a Gramma treid3@centurylink.net (Tom) (2017-04-17)
Re: Going backwards from a Language(or set of expressions) to a Gramma alain@universite-de-strasbourg.fr (Alain Ketterlin) (2017-04-17)
Re: Going backwards from a Language(or set of expressions) to a Gramma derek@_NOSPAM_knosof.co.uk (Derek M. Jones) (2017-04-17)
Re: Going backwards from a Language(or set of expressions) to a Gramma monnier@iro.umontreal.ca (Stefan Monnier) (2017-05-06)
| List of all articles for this month |
From: Stefan Monnier <monnier@iro.umontreal.ca>
Newsgroups: comp.compilers
Date: Sat, 06 May 2017 22:02:16 -0400
Organization: A noiseless patient Spider
References: 17-04-014
Injection-Info: miucha.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970"; logging-data="35446"; mail-complaints-to="abuse@iecc.com"
Keywords: parse, comment
Posted-Date: 06 May 2017 22:36:58 EDT

> [Depends what you mean by language. If you mean from a set of sentences,
> sure, it's this:


> lang ::= sentence1 | sentence2 | ...
> sentence1 ::= tokens in sentence1
> sentence2 ::= tokens in sentence2
> ...


Indeed. Actually, there's a more concise grammar that also accepts those
same sentences:


        lang = .*




-- Stefan
[Well, yeah, but that's a little overgeneral. -John]


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.