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: weakhash.go
    path of file: ./repos/syncthing/lib/weakhash
    
    the code of the file until where you have to start completion: // Copyright (C) 2016 The Syncthing Authors.
//
// This Source Code Form is subject to the terms of the Mo
    
func NewFinder(ctx context.Context, ir io.ReadSeeker, size int, hashesToFind []uint32) (*Finder, error) {
	offsets, err := Find(ctx, ir, hashesToFind, size)
	if err != nil {
		return nil, err
	}

	return &Finder{
		reader:  ir,
		size:    size,
		offsets: offsets,
	}, nil
}