code-translation

Convert PHP to C++ code [closed]

一世执手 提交于 2019-11-27 17:17:59
I'm looking for a way to convert PHP code to C++. There are a few reasons I want to do so: Main reason: There are bunch of great PHP tools/software that I'd love to use and incorporate into C++ GUI or non-GUI applications To boost performance To avoid dependency on PHP libraries To avoid disclosing source code on shared hosting environments To be empowered by C++ language features and make use of frameworks like Qt C++ and Poco So far I've found: http://sourceforge.net/projects/binaryphp http://www.mibsoftware.com/php2cpp/ Please share your ideas and tools that you know. Thank you in advance!

Counterpart to anonymous interface implementations in C#

╄→гoц情女王★ 提交于 2019-11-27 16:20:59
I'm working on translating some code from Java to C# but am having some trouble, maybe someone out there can help? I have problems trying to replicate anonymous interface implementations that are widely used in Java, but have no idea how to. An example is: List<DATA> queue1 = new ArrayList<DATA>(dataSet); // Sort by distance to the first promoted data Collections.sort(queue1, new Comparator<DATA>() { @Override public int compare(DATA data1, DATA data2) { double distance1 = distanceFunction.calculate(data1, promoted.first); double distance2 = distanceFunction.calculate(data2, promoted.first);

Does a Java to C++ converter/tool exist? [closed]

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-27 11:18:44
I always asked myself if it would be possible to make a Java to C++ converter. Maybe a tool that converts the Java syntax to the C++ syntax? I am aware that the languages differ, but simple things like loops where the semantics match 1 to 1. Is there such a tool? Or is it possible to make one? cletus It's possible to do anything given enough time, money and resources. Is it practical? Beyond trivial examples not really. Or rather it depends on what constitutes an acceptable error rate. The real problem is that the idioms are different in Java to C++. Java to C# for example would actually be

How to Cross-Compile Java Source Code to JavaScript?

限于喜欢 提交于 2019-11-27 09:50:13
问题 Given a set of Java source code files, how can I compile them into one or more JavaScript files that can be used with hand-crafted JavaScript? GWT is one option, but every example I've seen so far is aimed at building fancy websites. The simple use case of just converting Java source to Javascript that can be used together with handcrafted JavaScript hasn't been well-documented. I started a thread on the GWT mailing list on this subject, but opinions seem to be mixed on whether this is even

Writing code translator from Python to C? [closed]

强颜欢笑 提交于 2019-11-27 02:19:46
问题 I was asked to write a code translator that would take a Python program and produce a C program. Do you have any ideas how could I approach this problem or is it even possible? 回答1: Shedskin: http://code.google.com/p/shedskin/ Boost Python: http://www.boost.org/doc/libs/1_42_0/libs/python/doc/index.html PyCXX: http://cxx.sourceforge.net/ Cython: http://www.cython.org/ from http://wiki.python.org/moin/compile%20Python%20to%20C, there's a list of related projects. Pyrex: http://www.cosc

Counterpart to anonymous interface implementations in C#

萝らか妹 提交于 2019-11-26 22:26:53
问题 I'm working on translating some code from Java to C# but am having some trouble, maybe someone out there can help? I have problems trying to replicate anonymous interface implementations that are widely used in Java, but have no idea how to. An example is: List<DATA> queue1 = new ArrayList<DATA>(dataSet); // Sort by distance to the first promoted data Collections.sort(queue1, new Comparator<DATA>() { @Override public int compare(DATA data1, DATA data2) { double distance1 = distanceFunction

Tool to convert java to c# code [closed]

故事扮演 提交于 2019-11-26 21:42:01
What is the best tool out there at the moment to convert java to c#? Apart from j2ctranslator j# I use IKVM at the moment. Hendy Irawan For your reference: Sharpen by db4o XES RemoteSoft Octopus (commercial) Note: I had no experience on them. Don't. Leave them as Java and use IKVM to convert them to .Net DLLs. http://www.ikvm.net/devguide/java2net.html http://sourceforge.net/apps/mediawiki/ikvm/index.php?title=Ikvmc I've had good results with this one. Much easier to use than Sharpen. http://tangiblesoftwaresolutions.com/Product_Details/Java_to_CSharp_Converter.html Microsoft has a tool called

Convert PHP to C++ code [closed]

China☆狼群 提交于 2019-11-26 18:58:41
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . I'm looking for a way to convert PHP code to C++. There are a few reasons I want to do so: Main reason: There are bunch of great PHP tools/software that I'd love to use and incorporate into C++ GUI or non-GUI applications To boost performance To avoid dependency on PHP libraries To avoid disclosing source code

Is there an effective tool to convert C# code to Java code? [duplicate]

别说谁变了你拦得住时间么 提交于 2019-11-26 17:33:35
This question already has an answer here: Where can I find a Java to C# converter? [closed] 9 answers Is there an effective tool to convert C# code to Java code? I have never encountered a C#->Java conversion tool. The syntax would be easy enough, but the frameworks are dramatically different. Even if there were a tool, I would strongly advise against it. I have worked on several "migration" projects, and can't say emphatically enough that while conversion seems like a good choice, conversion projects always always always turn in to money pits. It's not a shortcut, what you end up with is code

How to convert C++ Code to C [closed]

白昼怎懂夜的黑 提交于 2019-11-26 11:44:33
I have some C++ code. In the code there are many classes defined, their member functions, constructors, destructors for those classes, few template classes and lots of C++ stuff. Now I need to convert the source to plain C code. I the have following questions: Is there any tool to convert C++ code and header files to C code? Will I have to do total rewrite of the code (I will have to remove the constructors,destructors and move that code into some init() , deinit() functions; change classes to structures, make existing member functions as function pointers in those newly defined structures and