   return if !set.dependencies[parentName]
   set.numDependencies -= 1
   delete set.dependencies[parentName]
+
+cloneDependencySet = (set) ->
+  clone = {}
+  for own parentName of set
+    clone[parentName] = true
+  clone
 
 compileDef = ([name, def]) ->
   if !def?

    def: [pattern, def]
    set: dependencySet()
    names: findNames pattern
    missing: []

  lookupByName = lookupTableForGraph graph


          addDependency child.set, name for name in parent.names unless child is parent
          addDependency deps, parent
        else if !node.label and !lookupIdentifier token, node
          addDependency child.missing, node.token
  [graph, lookupByName]

lookupTableForGraph = (graph) ->
