Add #where support for MemoryScope.

Did you mean to use 1.8 style hashes, or were you trying to restore the code to something matching the original code so the diff is minimized?