Issue 7621: Remove unecessary WeakMap