Ruby implementation for listing transitive dependencies among objects.