Revert 764ad41739710f5292ef57e741c6ec786da6500e

with better comments and variable names.

This fixes the reverse bundle test from browserify:
https://github.com/substack/node-browserify/pull/360