[PECOFF] Move a function out of a class

I'm going to use this function both for the import table and the
delay-import table.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@219267 91177308-0d34-0410-b5e6-96231b3b80d8
[mach-o] Support fat archives

mach-o supports "fat" files which are a header/table-of-contents followed by a
concatenation of mach-o files (or archives of mach-o files) built for
different architectures.  Previously, the support for fat files was in the
MachOReader, but that only supported fat .o files and dylibs (not archives).

The fix is to put the fat handing into MachOFileNode.  That way any input file
kind (including archives) can be fat.  MachOFileNode selects the sub-range
of the fat file that matches the arch being linked and creates a MemoryBuffer
for just that subrange.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@219268 91177308-0d34-0410-b5e6-96231b3b80d8