1#include <stdio.h>23#include <scc/mach.h>45#include "libmach.h"67#include "elf/fun.h"8#include "coff32/fun.h"910static int (*ops[NFORMATS])(char *) = {11 [COFF32] = coff32type,12 [ELF] = elftype,13};1415int16objtype(char *name)17{18 int t;19 int (**bp)(char *);2021 for (bp = ops; bp < &ops[NFORMATS]; ++bp) {22 if ((t = (**bp)(name)) >= 0)23 return t;24 }2526 return -1;27}