I am really struggling with ambigous types in scala...

I want to implement a StackManager which holds multiple stacks with different types... But something seems to be wrong.

```
object StackManager {

  val stacks = mutable.HashMap[String, mutable.Stack[_]]()
  def get[T](id: String): mutable.Stack[T] = {
    stacks.get(id) match {
      case Some(stack: mutable.Stack[T]) => stack
      case None => {
        val newStack = mutable.Stack[T]()
        stacks.put(id, newStack)
        newStack
      }
    }
  }
  def set[T](id: String, stack: mutable.Stack[T]) {
    stacks.put(id, stack)
  }
}

```

EDIT: With that I want to store different types of stacks in my manager:

```
StackManager.set[ClassA]("stack01", new mutable.Stack[ClassA]())
StackManager.set[ClassB]("stack02", new mutable.Stack[ClassB]())

StackManager.get[ClassA]("stack01") // returns the stack with type mutable.Stack[ClassA]
StackManager.get[ClassB]("stack02") // returns the stack with type mutable.Stack[ClassB]

```

EDIT2: scala version 2.9.2