home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!usc!zaphod.mps.ohio-state.edu!darwin.sura.net!uvaarpa!cv3.cv.nrao.edu!laphroaig!cflatter
- From: cflatter@nrao.edu (Chris Flatters)
- Subject: Re: Exponentiation operator proposal
- Message-ID: <1992Sep15.155654.17054@nrao.edu>
- Sender: news@nrao.edu
- Reply-To: cflatter@nrao.edu
- Organization: NRAO
- References: <1992Sep15.054226.4126@cc.tut.fi>
- Date: Tue, 15 Sep 1992 15:56:54 GMT
- Lines: 14
-
- In article 4126@cc.tut.fi, jk87377@cc.tut.fi (Juhana Kouhia) writes:
- >Instead of making exponential operator; I would like to get
- >a new basic operation which allows programmer to define new
- >operations like 'a ** b'; that is, the '**' is defined.
- >('a pow b' is also good.)
-
- Allowing the introduction of new operators on the fly is a nasty problem.
- Firstly, adding an operator means introducing a new lexeme which requires
- changing the lexical analyser on the fly. Secondly, the syntax analyser
- needs to be modified on the fly to be able to parse expressions involving
- the new operator. Neither of these are particularly easy to do.
-
- Chris Flatters
- cflatter@nrao.edu
-