37 research outputs found

    Adding external iterators to an existing Eiffel class library

    Get PDF
    Colloque avec actes et comité de lecture./http://ieeexplore.ieee.org/This paper discusses common iteration schemes and highlights the interest of using explicit iterators. The advantages of external iterators are compared to those of internalized iterators. The integration of an iterator class hierarchy to an existing library without modifying the latter is detailed. This integration brings an extra level of abstraction to the library, which thus becomes more flexible, more adapted to certain design patterns and hence can be used in a higher-level way. Such an integration is not only possible, but can even be done in an optimized way, taking into account the specific structure of the collection traversed. A slight extension of existing class libraries can also be implemented that does not cause any compatibility problem and does not break existing code, but allows even further abstraction and makes it easier for the developer to use high-level, optimized, external iterators

    The C++0x "Concepts" Effort

    Full text link
    C++0x is the working title for the revision of the ISO standard of the C++ programming language that was originally planned for release in 2009 but that was delayed to 2011. The largest language extension in C++0x was "concepts", that is, a collection of features for constraining template parameters. In September of 2008, the C++ standards committee voted the concepts extension into C++0x, but then in July of 2009, the committee voted the concepts extension back out of C++0x. This article is my account of the technical challenges and debates within the "concepts" effort in the years 2003 to 2009. To provide some background, the article also describes the design space for constrained parametric polymorphism, or what is colloquially know as constrained generics. While this article is meant to be generally accessible, the writing is aimed toward readers with background in functional programming and programming language theory. This article grew out of a lecture at the Spring School on Generic and Indexed Programming at the University of Oxford, March 2010

    Proposals for Enhancement for the Ada Programming Language: A Software Engineering Perspective

    Get PDF
    For an abstract and an HTML version of the thesis, please visit http://lgl.epfl.ch/Team/MW/Ada-Extensions/Ada-Extensions.html</a

    Proposals for enhancement of the Ada programming language:a software engineering perspective

    Get PDF
    This thesis is a critique of the Ada 83 programming language with emphasis on the construction of reusable components and their composition, and more generally on programming "in the large". Ada 83's deficiencies in that area are first described, and then solutions are proposed to most of the problems. The main part of the thesis is a proposal for object-oriented extensions, making classes and objects with inheritance available through package and task types, as a very natural extension of Ada 83's task types. These proposals can be viewed as an alternative to Ada 9X's tagged types, with which a comparison is made

    Generic Ownership Types for Java and the Collections Framework

    No full text
    Generic programming has turned out very useful in the development of reusable software. With the Java programming language, genericity is not only meant for reusability, but also for type-safety. Java generics constrain a container object (e.g., list, hash table) to store objects of a pre-specified data type. Nevertheless, safe programming with aliasing (multiple pointers in a program may point to the same object) is still a concern in object-oriented programming language research. A pointing object can mutate the state of the aliased object, reflecting the changes to all of the other pointers (aka aliases) thus affecting their behaviour. As programs grow larger and more complex, such changes in behaviour can be undesirable and difficult to detect and reason about. With respect to container objects, the iterator pattern critically violates encapsulation, allowing aliases to the state (and thereof the components) of its container. Object ownership is one of the well-researched paradigms in the area of alias management. Ownership types support hierarchical object encapsulation rather than the traditional class-level encapsulation. This thesis introduces an extension of Java 6 with support for ownership types as supplementary generic types. That is, Java generics are extended with the ability of carrying ownership information. This extension provides generic ownership support for all of Java; that is, all major language features are addressed so that programs can safely manage and express their aliasing properties. The resulting language is expressive enough to support common programming idioms, with little programming and runtime overhead. We evaluated the programmability of the language by refactoring a major (the most essential) portion of the Java Collections Framework. We also evaluated the performance impact of our refactoring by conducting a small micro-benchmark study to measure the performance time overhead the refactored collections may impose

    Grifon: a graphical interface to an object oriented database

    Get PDF
    The aim of the research outlined in this thesis is to establish what type of interface would be most suitable for object oriented databases. In particular it examines how graphical interface technologies might be used to present the database in a clearer form. In support of the research, a prototype interface system has also been developed to a commercial database to illustrate the practicality of the development of such an interface, and the increased effectiveness of the resultant system. The thesis outlines the features provided by the interface, the benefits accrued from such a system, and the problems associated with its development. Finally, it examines how such a system fits into the current work being carried out in the area of user interaction with databases

    Automating abstraction functions

    Get PDF
    Thesis (Ph. D.)--Massachusetts Institute of Technology, Dept. of Electrical Engineering and Computer Science, 2010.Cataloged from PDF version of thesis.Includes bibliographical references (p. 109-119).Data abstraction has been the dominant structuring paradigm for programs for decades. The essence of a data abstraction is the abstraction function, which relates the concrete program representation to its abstract meaning. However, abstraction functions are not generally considered to be a part of the executing program. We propose that making abstraction functions an executable part of the program can enable programmers to write clearer and more concise programs with fewer errors. In particular, we show that the object equality and hashing operations (which programmers are required to write), can often be expressed more clearly and more concisely in terms of the abstract state of the object. Getting these methods right has proven to be difficult for programmers at all skill levels, from novice through expert. In a case study of the standard Java libraries we show that rewriting the code with explicit declarative abstraction functions (and generating equality and hashing methods automatically) removed object-contract compliance faults previously found by Pacheco et al. To make abstraction functions part of the executing program we develop four techniques for the dynamic evaluation of abstraction functions written in a declarative first-order logic with relations and transitive closure. We observe that the abstraction functions programmers write in practice may often be viewed as navigation queries on the heap, and two of our techniques exploit this insight to synthesize executable code from declarative abstraction functions. The performance of our research prototype is within striking distance of hand-written code.by Derek F. Rayside.Ph.D
    corecore