Page 15 states "all objects visible at the point of package declaration are automatically accessible outside the package." For "outside" read "inside"!
In section 4.1, p66. the New_Garage_Attendant should not be a subtype. Rather, it should be:
task type New_Garage_Attendant( Pump : Pump_Number := Count.Assign_Pump_number) is entry Serve_Leaded(G: Gallons); entry Serve_Unleaded(G: Gallons); end New_Garage_Attendant;and the comment about subtyping tasks on page 67, although accurate is now redundant.
In section 6.11 there really ought to be a "use Activities" on page 130.
Also on page 132, there should be no discriminant on the body of task Phil and the body should say "end Phil"!
On page 142, second sentence "condition entry calls" -> "conditional entry calls"
On page 165 section 7.12 "blocked on an entry call" -> "waiting on a protected entry call"
On page 193 Capacity should be of type "Positive".
On bottom of page 204, Max_No_Blocks_on_Disk should be of type Positive On top of page 205, Size should be of type Positive.
In Section 9.5, page 208 we present a generic Buffers package. In moving to the Second edition, we changed the type Capacity_Range to be a mod type. Unfortunately, mod types need a static range which precludes their use with a generic parameter. Our thanks to Prof. Dr. Theodor Tempelmeier for pointing out the problem. The package should be
generic type Message is private; Max_Capacity : Positive := 10; --set to some appropriate value package Buffers is subtype Capacity_Range is Natural range 0 .. Max_Capacity - 1; subtype Count is Integer range 0 .. Max_Capacity; type Buffer_Array is array(Capacity_Range) of Message; protected type Buffer is entry Get (Item: out Message); entry Put(Item: in Message); function Buffer_Capacity return Positive; private First : Capacity_Range := Capacity_Range'first; Last : Capacity_Range := Capacity_Range'last; Number_In_Buffer : Count := 0; Store : Buffer_Array; end Buffer; end Buffers; package body Buffers is protected body Buffer is entry Get(Item: out Message) when Number_In_Buffer /= 0 is begin Item := Store(First); First := (First + 1) mod Max_Capacity; Number_In_Buffer := Number_In_Buffer - 1; end Get; entry Put(Item: in Message) when Number_In_Buffer /= Max_Capacity is begin Last := (Last +1) mod Max_Capacity; Store(Last) := Item; Number_In_Buffer := Number_In_Buffer + 1; end Put; function Buffer_Capacity return Positive is begin return Max_Capacity; end Buffer_Capacity; end Buffer; end BUFFERs;
on page 211, the definitions of Max_Group_Size and Default_group_Size should be initialised to "...;"
On page 213, "requeue Wait_Next_Message" should be "requeue Wait_Next_Message with abort"
On page 284 (twice, bottom of page) and 288 (top of the code), "FIFO_Within_Priority" should be "FIFO_Within_Priorities".