

def matching_files(patterns):
    for pattern in patterns:
        if os.path.isfile(pattern):
            (yield pattern)
        elif os.path.isdir(pattern):
            for (dirpath, dirnames, filenames) in os.walk(patterns):
                for filename in filenames:
                    (yield os.path.join(dirpath, filename))
        else:
            for filename in glob.glob(pattern):
                (yield filename)

dataset/ETHPy150Open akheron/stango/stango/autoreload.py matching_files/VarMisuse@60/65 `pattern`->`patterns`