このコード スニペットを考えると
def doSomething() = {
val associations : HashMap[Int, Int] = function_that_create_a_hashmap
println("something")
}
がdoSomething終了すると、変数associationsの割り当てが解除されますか? その上でいくつかのデストラクタを呼び出す必要がありますか (.clearこの場合はおそらく )、またはその操作は役に立ちませんか?