Fix remaining bug with letrec
Add deadlock analysis for language with locks