     if args.length % 2 != 0
       return malformed ctx, args[args.length - 1], 'Missing value for key'
     [labels, items] = unzip pairs args
-    compiledLabels = termsCompileExpectingSameType ctx, labels
-    keyType = applyKindFn hashmapType, compiledLabels.itemType
+    compiledLabels = termsCompileExpectingSameType ctx, call, labels
+    keyType = applyKindFn hashmapType(), compiledLabels.itemType
     compiledItems = uniformCollectionCompile ctx, call, items, keyType,
       compiledLabels.constraints
     assignCompile ctx, call, (irMap compiledLabels.compiled, compiledItems)


typeFn = (argType, args...) ->
  if _empty args
    new TypeApp zeroArrowType, argType
  else
    properTypeFn argType, args...


    elemType = ctx.freshTypeVariable star
    # TODO use (Seq c e) instead of (Array e)
    form.tea = new Constrained (concatMap _constraints, (map _tea, elems)),
      (markOrigin (new TypeApp arrayType(), elemType), form)

    for elem in elems
      unify ctx, elem.tea.type,
