Is there any tool which converts the source code in one language to other...
Asked
Active
Viewed 3,379 times
1
-
1what a great subcontracter you are. – Andrew Bullock Aug 13 '10 at 12:03
-
I think you're going to have to be a bit more specific than that.... – Aidan Kane Aug 13 '10 at 12:17
-
To be more specific. I am actually looking for converting a code return in Java to C# – Balaji.N.S Aug 13 '10 at 12:36
-
You didn't understand the concept of different programming languages, did you? :-/ – Reactormonk Aug 13 '10 at 13:07
-
1It's called a transcompiler in general. There are many available, you might want to check this out http://en.wikipedia.org/wiki/Source-to-source_compiler – Ragunath Jawahar Dec 31 '12 at 05:31
2 Answers
2
You can look at TXL, a program transformation tool that has been used to implement language-to-language translators.
EDIT: (after OP clarified his question slightly in a comment) You aren't very clear about the translations direction: Java-to-C# or C#-to-Java. However, this SO thread seems to address both to some degree: Is there an effective tool to convert C# code to Java code? (the link is really to convert-c#-to-java; SO apparantly can't put a # in a link).

Community
- 1
- 1

Ira Baxter
- 93,541
- 22
- 172
- 341
0
The only tool I know of that has anything like this is LLVM which provides a C backend, i.e. it should be able generate C code from any language for which there is an LLVM front-end.

Christoffer
- 12,712
- 7
- 37
- 53