You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: create_events_mock_contract.go
    path of file: ./repos/chainlink/core/gethwrappers/generation/generate_events_mock
    
    the code of the file until where you have to start completion: package main

import (
	"bytes"
	"encoding/json"
	"fmt"
	"os"
	"path/f
    
func generateFunctions(solEvents []SolEvent) ([]SolFunction, error) {
	var solFunctions []SolFunction

	for _, event := range solEvents {
		var solParams []SolFunctionParam

		for _, eventParam := range event.Params {
			memory := false
			if eventParam.Type == "bytes" || eventParam.Type == "string" || strings.HasSuffix(eventParam.Type, "[]") ||
				eventParam.InternalType == "struct" {
				memory = true
			}
			funcParam := SolFunctionParam{
				Type:   eventParam.Type,
				Memory: memory,
				Name:   eventParam.Name,
			}
			solParams = append(solParams, funcParam)
		}

		solFunctions = append(solFunctions, SolFunction{
			Name:      "emit" + event.Name,
			EventName: event.Name,
			Params:    solParams,
		})
	}

	return solFunctions, nil
}