Subroutines and Control Abstraction Flashcards
What is a Control Abstraction?

What goes on behind the scenes when calling a subroutine?

What are the three main places when maintaining a stack?

Calling Sequence Info:

Function caller or callee tasks:

One thing that can be done with procedures is inline expansion. What is this?

What are some inline keywords in C and Ada?

Parameter Passing Info:

Parameter Passing by Value:

Parameter Passing by Reference:

Parameter Passing by Read Only:

Parameter Passing by Sharing:

Three modes in Ada for passing parameters:

References in C++:

Passing Parameters by Name:

Some languages support named parameters that can be given an any order:

Some languages support a variabled number of parameters:

Many languages restrict what can be returned from a function. What are some examples?

Generic Subroutines and Modules

Implicit Parametric Polymorphism

Explicit Polymorphic Generics

What kind of types can be passed as a generic parameter?

Implementation Options for Generic Parameters:

(T/F)
In some languages, all instances share the same code at runtime.
True

Constraints on Generic Parameters:

Generic Parameters Constraints in Ada:

Generic Parameter Constraints in Java:

C++ templates are very powerful. Elaborate:

What is an exception?

What are some solutions for exceptions?

In ML, what could be a good way to recover from an exception?

What are some exception handling mechanisms?

What can an exception handler do?

Exception in Java:

Exception Handling Techniques:

Exception Handling Using a Table:

What is the philosophy of exceptions?

Explain Coroutines:
