Newsgroups: comp.lang.c Path: utzoo!henry From: henry@utzoo.uucp (Henry Spencer) Subject: Re: evaluating math w/o recompile Message-ID: <1989Sep15.154336.28487@utzoo.uucp> Organization: U of Toronto Zoology References: <7598@goofy.megatest.UUCP> <34566@apple.Apple.COM> <556@tigger.planet.bt.co.uk> <451@siswat.UUCP> <72603@yale-celray.yale.UUCP> Date: Fri, 15 Sep 89 15:43:36 GMT In article <72603@yale-celray.yale.UUCP> zador-anthony@CS.YALE.EDU (anthony zador) writes: >I would like to be able to specify the form of the function f >at *run time* (no recompiles). That is, i would like >to place a line of math >in some file and have the program read it in and evaluate it. You can't. There is no way that line of math can be *executed* without compiling it (in a very broad sense of the word), so trying to do it with no recompiles is futile. Either you invoke the C compiler, or you write a mini-compiler as part of your program. *Something* has to turn the math notation into an executable/interpretable representation of some kind. -- V7 /bin/mail source: 554 lines.| Henry Spencer at U of Toronto Zoology 1989 X.400 specs: 2200+ pages. | uunet!attcan!utzoo!henry henry@zoo.toronto.edu