Issues #215 and #223

This is a partial implementation of what @berkmark described in https://github.com/faylang/fay/issues/223#issuecomment-13060082. It seems to resolve the specific issues of #215 and #223, though I believe there are a few more bugs to be worked out (I'm still investigating).