This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Input and print statements for Front End?
- From: Paul Brook <paul at codesourcery dot com>
- To: gcc at gcc dot gnu dot org
- Cc: "Harry Goulding" <yarrh_17 at hotmail dot com>
- Date: Wed, 6 Apr 2005 13:39:32 +0100
- Subject: Re: Input and print statements for Front End?
- Organization: CodeSourcery
- References: <BAY12-F23AB5A08209D04A3368DA5E63D0@phx.gbl>
On Wednesday 06 April 2005 13:00, Harry Goulding wrote:
> Hi All,
>
> I'm developing a front end for a simple programming language as part of a
> project.
>
> I have looked through the GCC Internals Manual, the Toy front end language
> and Treelang.
>
> I can't seem to find any info regarding an input or print statement, so i
> can read integers(my language only deals with integers) from the stdio and
> return integer results to stdio.
Interfacing with the OS is the resposibility of your language runtime library,
not the compiler itself..
You might want to look at how the fortran intrinsic functions an IO routines
are handled. Basically the language define IO constructs are turned into a
sequence of function calls.
Paul