Larry Coon a �crit dans le message <348D7832.27A4@assist.org>... >Here's some contrived code to illustrate what I'm >trying to do: > >procedure main is > protected type semaphore is > entry seize; > procedure release; > private > available: boolean := true; > end semaphore; > > -- The usual implementation of a semaphore. > protected body semaphore is separate; > > task type t; > task body t is separate; > > task_count: positive; >begin -- main > put ("Enter number of tasks: "); > get (task_count); > declare > subtype task_range is integer range 1..task_count; > semaphore_array: array (task_range) of semaphore; You could declare your task type HERE, it will have visibility on the semaphores. The only thing you'll loose is the ability to have the task body separate, but if you use a subprogram rather than a nested block statement, you would get this feature back. > task_array: array (task_range) of t; > begin > null; > end; >end;