首页 | 本学科首页   官方微博 | 高级检索  
     


Extending type systems in a library: Type-safe XML processing in C++
Authors:Yuriy Solodkyy,Jaakko Jä  rvi
Affiliation:
  • Texas A&M University, College Station, TAMU 3112, TX 77843, USA
  • Abstract:Type systems built directly into the compiler or interpreter of a programming language cannot be easily extended to keep track of run-time invariants of new abstractions. Yet, programming with domain-specific abstractions could benefit from additional static checking. This paper presents library techniques for extending the type system of C++ to support domain-specific abstractions. The main contribution is a programmable “subtype” relation. As a demonstration of the techniques, we implement a type system for defining type qualifiers in C++, as well as a type system for the XML processing language, capable of, e.g., statically guaranteeing that a program only produces valid XML documents according to a given XML schema.
    Keywords:Type systems   XML   Type qualifiers   C++   Template metaprogramming   Active libraries
    本文献已被 ScienceDirect 等数据库收录!
    设为首页 | 免责声明 | 关于勤云 | 加入收藏

    Copyright©北京勤云科技发展有限公司  京ICP备09084417号