Revert "dict: Rework reference counting" This reverts commit 18bbdb51175f309aef40fa5254af34e322be7783 due to lack of feedback.