Traducción automatizada de programas entre lenguajes de operaciones
DOI:
https://doi.org/10.29019/enfoqueute.v3n1.8Keywords:
Lenguajes de programación, lenguajes de operaciones, transformaciones de código, traductores de lenguajes, Programming languages, operations languages, code transformations, languages translatorsAbstract
Los lenguajes de operaciones se usan para programar, en procedimientos organizados, las instrucciones a ser ejecutadas por una máquina, para realizar distintos tipos de operaciones. Para poder importar procedimientos existentes realizados en un lenguaje de operaciones dado, en frameworks de programación específicos para el diseño de operaciones, es necesario contar con traductores entre el lenguaje en que ha sido programado el procedimiento, y el lenguaje interno utilizado por el framework de diseño. La construcción de estos traductores puede ser automatizada si se establece un mapeo entre producciones equivalentes de las gramáticas de los lenguajes fuente y destino. Las producciones se pueden considerar equivalentes cuando a pesar de tener una sintaxis diferente, tienen la misma intención semántica y pueden ser equiparadas con un árbol de sintaxis abstracta en común. Debido a ciertas diferencias sintácticas, en ocasiones este árbol sintáctico común no puede ser hallado directamente. Esto se vuelve posible, sin embargo, al realizar en primer lugar ciertas transformaciones a los programas. Este artículo presenta un acercamiento específico a la construcción de reglas de transformación para resolver estas diferencias.
Abstract:
Operations languages are used to program the procedures that instruct machinery to perform specific operations. To import procedures in a given operations language, into a dedicated tool for designing operations, language translators are needed to translate those procedures to the design tool's internal operations language. The construction of these translators can be automated by mapping equivalent productions in the grammar of source and target language. Productions are considered equivalent when, in spite of a differing syntax, they have the same intended semantics and can be matched to a same abstract syntax tree. For some corresponding productions, due to syntactic differences, such a common abstract syntax tree cannot be found directly. However, they can be made to match by performing some specific program transformations first. This paper presents a specific approach to write transformation rules to resolve such mismatches.
Downloads
Downloads
Published
How to Cite
Issue
Section
License
The articles and research published by the UTE University are carried out under the Open Access regime in electronic format. This means that all content is freely available without charge to the user or his/her institution. Users are allowed to read, download, copy, distribute, print, search, or link to the full texts of the articles, or use them for any other lawful purpose, without asking prior permission from the publisher or the author. This is in accordance with the BOAI definition of open access. By submitting an article to any of the scientific journals of the UTE University, the author or authors accept these conditions.
The UTE applies the Creative Commons Attribution (CC-BY) license to articles in its scientific journals. Under this open access license, as an author you agree that anyone may reuse your article in whole or in part for any purpose, free of charge, including commercial purposes. Anyone can copy, distribute or reuse the content as long as the author and original source are correctly cited. This facilitates freedom of reuse and also ensures that content can be extracted without barriers for research needs.
This work is licensed under a Creative Commons Attribution 3.0 International (CC BY 3.0).
The Enfoque UTE journal guarantees and declares that authors always retain all copyrights and full publishing rights without restrictions [© The Author(s)]. Acknowledgment (BY): Any exploitation of the work is allowed, including a commercial purpose, as well as the creation of derivative works, the distribution of which is also allowed without any restriction.