26 Dec 1996 14:05:49 -0500

Related articles |
---|

[7 earlier articles] |

Re: User definable operators burley@gnu.ai.mit.edu (Craig Burley) (1996-12-18) |

Re: User definable operators jdean@puma.pa.dec.com (1996-12-18) |

Re: User definable operators neitzel@gaertner.de (1996-12-18) |

Re: User definable operators tim@franck.Princeton.EDU (1996-12-20) |

Re: User definable operators nkramer@cs.cmu.edu (Nick Kramer) (1996-12-20) |

Re: User definable operators hrubin@stat.purdue.edu (1996-12-24) |

Re: User definable operators preston@tera.com (1996-12-26) |

Re: User definable operators burley@gnu.ai.mit.edu (Craig Burley) (1996-12-26) |

Re: User definable operators mfinney@inmind.com (1996-12-26) |

Re: User definable operators leichter@smarts.com (Jerry Leichter) (1996-12-27) |

Re: User definable operators genew@mindlink.bc.ca (1996-12-28) |

Re: User definable operators WStreett@shell.monmouth.com (1996-12-29) |

Re: User definable operators adrian@dcs.rhbnc.ac.uk (1997-01-02) |

[6 later articles] |

From: | preston@tera.com (Preston Briggs) |

Newsgroups: | comp.compilers |

Date: | 26 Dec 1996 14:05:49 -0500 |

Organization: | /etc/organization |

References: | 96-12-110 96-12-147 96-12-163 |

Keywords: | design |

*>>example, "f(a+b)" means either f evaluated at a + b, or f times a + b,*

*>>depending whether f is a function or not. If you consider that*

*>>functions can really be expressions too (like (f \compose g)(a + b))*

*>>things get worse. Mathematica uses [] for functions for this very*

*>>reason.*

*>*

*>This particular ambiguity is typically blocked in most computer*

*>languages anyhow. In any of them, using xy for the product of x and y*

*>is prohibited, and I know of none for which even 2x is allowed.*

I know of a couple that allow this sort of thing.

HAL and HAL/S (basically an extension of PL/1) allow things like

X = A X + Y

meaning X is replaced by the sum of Y and the product of A and X. Of

course, they also allowed things like superscripts and subscripts, and

had matrices and vectors along with primitives to operate upon them.

A more interesting example, perhaps, is Metafont, Knuth's language for

specifying type fonts.

Preston Briggs

--

Post a followup to this message

Return to the
comp.compilers page.

Search the
comp.compilers archives again.