how to support floating point in a C interpreter

Jean-Christophe Plouvier <plouvier@lavoisier.learning.cs.cmu.edu>
Thu, 29 Aug 91 13:46:02 EDT

          From comp.compilers

Related articles
how to support floating point in a C interpreter plouvier@lavoisier.learning.cs.cmu.edu (Jean-Christophe Plouvier) (1991-08-29)
| List of all articles for this month |

Newsgroups: comp.compilers,comp.lang.c
From: Jean-Christophe Plouvier <plouvier@lavoisier.learning.cs.cmu.edu>
Keywords: C, question, interpreter
Organization: Compilers Central
Date: Thu, 29 Aug 91 13:46:02 EDT

hi,


I found in the literature source code for a simple C interpreter. Now I want
to extend the data type from int,char to float, arrays, structures....but
let's focus on floating points. I think I should use a C++ class (token)
handling the token type, the token name and value under an anonymous union
etc.. with some with some functions... also I do not know how to deal with
expression evaluation*,+,-.. when mixing different data types: should I over;
overload operators.??.. To be honnest, I am LOST! and need help.


I am programming in C/C++ zortech on PC. I am not a CS specialist therefore I
would appreciate your help in any form: lines of code, references..


Thank you in advance


JC Plouvier.


Please respond to plouvier@lavoisier.learning.cs.cmu.edu
or plouvier@cs.cmu.edu or jp3t@andrew.cmu.edu.


--


Post a followup to this message

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