scispace - formally typeset
Journal ArticleDOI

Simplifying the construction of source code transformations via automatic syntactic restructurings

TLDR
A set of restructurings to systematically normalize selective syntax in C++ is presented to convert variations in syntax of specific portions of code into a single form to simplify the construction of large, complex program transformation rules.
Abstract
A set of restructurings to systematically normalize selective syntax in C++ is presented. The objective is to convert variations in syntax of specific portions of code into a single form to simplify the construction of large, complex program transformation rules. Current approaches to constructing transformations require developers to account for a large number of syntactic cases, many of which are syntactically different but semantically equivalent. The work identifies classes of such syntactic variations and presents normalizing restructurings to simplify each variation to a single, consistent syntactic form. The normalizing restructurings for C++ are presented and applied to two open source systems for evaluation. The evaluation uses the system's test cases to validate that the normalizing restructurings do not affect the systems' tested behavior. In addition, a set of example transformations that benefit from the prior application of normalizing restructurings are presented along with a small survey to assess the effect of the readability of the resultant code.

read more

Citations
More filters

The Spoofax language workbench rules for declarative specification of languages and IDEs

TL;DR: Spoofax as mentioned in this paper is a language workbench for efficient, agile development of textual domain-specific languages with state-of-the-art IDE support, integrating language processing techniques for parser generation, meta-programming, and IDE development into a single environment.
Posted Content

Transformation of Python Applications into Function-as-a-Service Deployments

TL;DR: This paper introduces and evaluates Lambada, a Python module to dynamically decompose, convert and deploy unmodified Python code into AWS Lambda functions and contributes a description of the algorithms and code rewriting rules as blueprints for transformations of other scripting languages.
Journal ArticleDOI

A study of code change patterns for adaptive maintenance with AST analysis

TL;DR: This work collected the adaptive commits from the history of numerous open source systems, then obtained the repetitiveness frequencies of source code changes based on the analysis of Abstract Syntax Tree (AST) edit actions within an adaptive commit to suggest a set of change patterns that seem correlated with adaptive maintenance.
References
More filters
Book

Refactoring: Improving the Design of Existing Code

TL;DR: Almost every expert in Object-Oriented Development stresses the importance of iterative development, but how do you add function to the existing code base while still preserving its design integrity?
Journal ArticleDOI

Term rewriting and all that

TL;DR: Term Rewriting and All That is a self-contained introduction to the field of term rewriting and covers all the basic material including abstract reduction systems, termination, confluence, completion, and combination problems.
Proceedings ArticleDOI

The spoofax language workbench: rules for declarative specification of languages and IDEs

TL;DR: The architecture of Spoofax is described and idioms for high-level specifications of language semantics using rewrite rules are introduced, showing how analyses can be reused for transformations, code generation, and editor services such as error marking, reference resolving, and content completion.
Book ChapterDOI

Stratego: A Language for Program Transformation Based on Rewriting Strategies System Description of Stratego 0.5

TL;DR: In this article, a rewrite rule is defined as a natural formalism for expressing single program transformations, such as compilation, optimization, synthesis, refactoring, migration, normalization and improvement.
Proceedings ArticleDOI

RASCAL: A Domain Specific Language for Source Code Analysis and Manipulation

TL;DR: Rascal is a domain-specific language that takes away most of this boilerplate by integrating source code analysis and manipulation at the conceptual, syntactic, semantic and technical level.