code: function generateFunctionMap(ast: Ast): FBSourceFunctionMap {
    const encoder = new MappingEncoder();
    forEachMapping(ast, mapping => encoder.push(mapping));
    return encoder.getResult();
  }
docs: Generate a map of source positions to function names. The names are meant to
  describe the stack frame in an error trace and may contain more contextual
  information than just the actual name of the function.
  
  The output is encoded for use in a source map. For details about the format,
  see MappingEncoder below.