z-logo
open-access-imgOpen Access
Language composition using source code annotations
Author(s) -
Milan Nosáľ,
Matúš Sulír,
Ján Juhár
Publication year - 2016
Publication title -
computer science and information systems
Language(s) - English
Resource type - Journals
eISSN - 2406-1018
pISSN - 1820-0214
DOI - 10.2298/csis160114024n
Subject(s) - computer science , programming language , unification , syntax , embedding , formal grammar , abstract syntax , source code , natural language processing , set (abstract data type) , extension (predicate logic) , semantics (computer science) , formal semantics (linguistics) , formal language , context (archaeology) , domain (mathematical analysis) , artificial intelligence , rule based machine translation , paleontology , biology , mathematical analysis , mathematics
In this paper we examine source code annotations from the viewpoint of formal languages - we discuss their abstract syntax, concrete syntax, and semantics, thus showing the correspondence between annotations and formal languages. We propose to consider a set of all annotations and their parameters processed by the same reference implementation (they belong to the same domain) to be called an annotation-based language. The performed analysis also pinpoints a specificity of annotations in comparison with formal languages in general - the binding between annotations and a host language. We elaborate this idea with an analysis of annotations’ potential for language composition, in particular for pure embedding. We then show how pure embedding with annotations can be used for language unification, language referencing by extension, and language extension. This work provides a basis for further research in the field of source code annotations in the context of formal languages.

The content you want is available to Zendy users.

Already have an account? Click here to sign in.
Having issues? You can contact us here
Accelerating Research

Address

John Eccles House
Robert Robinson Avenue,
Oxford Science Park, Oxford
OX4 4GP, United Kingdom