• Home
  • Search
  • Attached Types and Their Application to Three Open Problems of Object-Oriented Programming
  • Cite Icon19
  • https://doi.org/10.1007/11531142_1Copy DOI Icon

Attached Types and Their Application to Three Open Problems of Object-Oriented Programming

  • Jan 1, 2005
  • Bertrand Meyer
Show More
  • Abstract
  • Literature Map
  • References
  • Citations
  • Similar Papers
Abstract

Abstract The three problems of the title — the first two widely discussed in the literature, the third less well known but just as important for further development of object technology — are:– Eradicating the risk of void calls: x.f with, at run time, the target x not denoting any object, leading to an exception and usually a crash.– Eradicating the risk of “catcalls”: erroneous run-time situations, almost inevitably leading to crashes, resulting from the use of covariant argument typing.– Providing a simple way, in concurrent object-oriented programming, to lock an object handled by a remote processor or thread of control, or to access it without locking it, as needed by the context and in a safe way.A language mechanism provides a combined solution to all three issues.This mechanism also allows new solutions to two known problems: how to check that a certain object has a certain type, and then use it accordingly (“Run-Time Type Identification” or “downcasting”), for which it may provide a small improvement over previously proposed techniques; and how to provide a “once per object” facility, permitting just-in-time evaluation of certain object properties.The solution relies on a small extension to the type system involving a single symbol, the question mark. The idea is to declare certain types as “attached” (not permitting void values), enforce some new validity rules that rule out void calls, and validate a number of common programming schemes as “Certified Attachment Patterns” guaranteed to rule out void calls. (In addition, the design replaced an existing type-querying construct by a simpler one.)The mechanism is completely static: all checks can be performed by compilers as part of normal type system enforcement. It places no undue burden on these compilers — in particular, does not require dataflow analysis — and can be fairly quickly explained to programmers. Existing code, if reasonably well-written, will usually continue to work without change; for exceptions to this rule, often reflecting real risks of run-time crashes, backward-compatible options and a clear transition path are available.KeywordsFormal ArgumentValidity RuleProgram TextExpanded TypeCreation InstructionThese keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Similar Papers
  • Supplementary Content

Co-Contextual Type Systems: Contextless Deductive Reasoning for Correct Incremental Type Checking

  • Mar 02, 2020
  • TUbilio (Technical University of Darmstadt)
  • Edlira Kuci
  • Research Article
  • Citations14

Should ML be Object-Oriented?

  • Jul 01, 2002
  • Formal Aspects of Computing
  • David Macqueen
  • Conference Article
  • Citations66

Gradual typing for first-class classes

  • Oct 19, 2012
  • Asumu Takikawa +4
  • Conference Article
  • Citations7

The heart of object-oriented concurrent programming

  • Jan 01, 1988
  • J Lim +1
  • PDF
  • Research Article
  • Citations1

Integration of aspect-oriented approach means in object-oriented programming language

  • Apr 22, 2016
  • Eastern-European Journal of Enterprise Technologies
  • Valentina Medvedeva +1
  • Book Chapter
  • Citations96

First-Class Relationships in an Object-Oriented Language

  • Jan 01, 2005
  • Gavin Bierman +1
  • PDF
  • Research Article

Frequent Statement and Dereference Elimination for Imperative and Object-Oriented Distributed Programs

  • Jan 01, 2014
  • The Scientific World Journal
  • Mohamed A El-Zawawy
  • Research Article
  • Citations24

Improved typings for probabilistic noninterference in a multi-threaded language

  • Dec 01, 2006
  • Journal of Computer Security
  • Geoffrey Smith
  • Conference Article
  • Citations2

Imperative objects with dependent types

  • Jul 07, 2015
  • Joana Campos +1
  • Research Article
  • Citations1

Dynamic overloading with copy semantics in object-oriented languages: a formal account

  • Mar 12, 2009
  • RAIRO - Theoretical Informatics and Applications
  • Lorenzo Bettini +2
  • Research Article
  • Citations4

A hierarchical and reflective framework for synchronization and scheduling controls

  • Sep 01, 1996
  • Future Generation Computer Systems
  • Tzilla Elrad +1
  • Research Article

First-class effect reflection for effect-guided programming

  • Oct 19, 2016
  • ACM SIGPLAN Notices
  • Yuheng Long +2
  • Research Article
  • Citations30

A lightweight cryptography (LWC) framework to secure memory heap in Internet of Things

  • Nov 19, 2020
  • Alexandria Engineering Journal
  • Mahmoud Khalifa +4
  • Conference Article
  • Citations4

A type system extension for middleware interactions

  • Jan 01, 2007
  • Sven De Labey +1
  • Research Article
  • Citations3

Depot4 — Agenerator for dynamically extensible translators

  • Mar 01, 1998
  • Software - Concepts & Tools
  • Jürgen Lampe
Cactus Communications logo

Copyright 2026 Cactus Communications. All rights reserved.