   scope.frameSize = bind.spOffset + bind.type.size
   return
 
-# Condense a typed scope to a map of variable names to sp offsets.
-spOffsets = (scope) ->
-  offsets = []
-  for { name, type: bind } in scope.variables when bind.onStack
-    offsets.push { name, offset: bind.spOffset, ty: bind.type }
-  offsets
-
 # Dereference something in a heap view.
 makeDeref = (o, base, baseTy, offset, offsetTy) ->
   new Value offsetTy.view(o), [new Index offsetExpr base, baseTy, offset, offsetTy]

    # argument.
    exprs = @body.expressions
    for param in @params
      for arg in param.variables
        if arg.binding.onStack
          arg.save = freshVariable arg.name
          plh = new Value new Literal arg.name
          prh = new Value arg.save
          asn = new Assign plh, prh
          asn.computedType = plh.computedType = prh.computedType = arg.type
          plh.computedBinding = arg.binding
          exprs.unshift asn
    o.frameSize = frameSize
    stackFence o, exprs, frameSize, @spOffsets
    for param in @params
      for { name, save } in param.variables
        exprs.unshift new Assign new Value(save), new Value new Literal name
  return

# Add SP computation and pointer conversions to explicit returns.

    exprs = @expressions
    if frameSize = @frameSize
      o.frameSize = frameSize
      stackFence o, exprs, frameSize, yes
    # Bring in `malloc` if this module needs it.
    if scope.needsMalloc
      obj = new Value new Obj [MALLOC, FREE]
