This description relates to source code translation, and in particular, to translation of source code specified in one or more original software programming languages to one or more other, different software programming languages.
In the field of software development, software engineers can choose to develop software in one or more of a number of different programming languages. At the time of this writing, some examples of modern programming languages conventionally used by developers are Java, C#, and C++. In general, each programming language has its advantages and disadvantages and it is the job of the software engineer to take these advantages and disadvantages into account when choosing an appropriate programming language for a given application.
Over the years, the state of the art in programming languages has advanced, causing certain early programming languages to become less used, no longer supported, and/or obsolete. Some examples of such early programming languages are Basic and Fortran. Still, source code written in those early programming languages, often referred to as “legacy” code, commonly remains in production for many years due to its adequate performance. However, when such legacy code ceases to adequately function and changes to the code become necessary, it can be difficult to find software engineers who have the necessary skills to update the legacy code.
For this reason, source-to-source compilers have been developed, which receive a first software specification specified in a first programming language as input and generate a second software specification specified in a second, different programming language as output. Such source-to-source compilers are used to translate legacy code into modern programming languages, which are more easily edited by software engineers skilled in the use of modern programming languages.