! In the C translation, local should be 'static' not external or auto...
routinespec local(integer i)

externalroutine fred
  local(2)
end

routine local(integer i)
  write(i,0); newline
end

begin
  routinespec jim(integer i)
  jim(22)
  routine jim(integer i)
    fred
  end
end

endoffile