Abstract
Ada and Java are two languages that rely heavily on exceptions. A large part of the Ada data model is based on the fact that data is checked at run time, and will raise various kinds of exceptions such as Constraint_Error when constraints are violated. Similarly, there are many cases where Java performs checks that can raise exceptions, among the most common being checks on casts and null dereferences. It is therefore extremely important to support exceptions that are properly propagated from one language to the other and even potentially caught/handled, without having to worry about the language of origin.
Index Terms
Gem #58: Ada / Java exception handling
Recommendations
Gem #55: introduction to Ada / Java interfacing
Interfacing Ada and Java is a very tricky problem. As opposed to C, C++, or Fortran, the two languages execute on two different environments, Java on the JVM and Ada directly on the underlying OS. For this reason, it is not possible to directly bind ...
Gem #142: Exception-ally
The standard Ada run-time library provides the package Ada.Exceptions. This package provides a number of services to help analyze exceptions. Each exception is associated with a (short) message that can be set by the code that raises the exception. In ...
Gem #52: scripting capabilities in GNAT (Part 1)
Ada Gem #52 -- Programming languages are, at least in the mind of most programmers, divided into two categories: scripting languages and others. The dividing line is not always obvious, and generally has to do with the size of the application, whether ...






Comments