Detect cycles involving types bounded by singleton types

This fixes #193, but I don't know if it breaks other things :).

Review by @odersky @DarkDimius @namin .