[mercury-users] Back end
Fergus Henderson
fjh at cs.mu.OZ.AU
Fri Mar 14 23:25:52 AEDT 2003
On 14-Mar-2003, Simon Taylor <stayl at cs.mu.OZ.AU> wrote:
> On 14-Mar-2003, suja c <suja_cin at yahoo.com> wrote:
> > I tried to compile the hello_world program with the
> > option below , to get the java code.
> >
> > mmc hello_world.m --grade java
> >
> > i got an error saying javac not available.
> > I just want to see teh java program. I dont want to
> > execute it.
>
> mmc -C hello_world.m --grade java
>
> The command above should have generated the Java file before
> reporting an error.
>
> > What should I do for that. I want a
> > detailed description regarding how to do this and also
> > generate back ends using other languages such as c,il,
> > .net and aditi.
>
> For C
> mmc -C hello_world.m
>
> For IL (.NET)
> mmc -C --grade il hello_world.m
Yes. Or you can use `--target-code-only' instead of `-C' if you prefer
(the two are synonyms).
You may also find that the generated C code is easier to read if you
use the `-n-' option (or its long form, `--no-line-numbers').
This suppresses the generation of "#line" directives.
--
Fergus Henderson <fjh at cs.mu.oz.au> | "I have always known that the pursuit
The University of Melbourne | of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh> | -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list