Move include block to pathstuff.h
authorTom Tromey <tromey@adacore.com>
Mon, 9 Nov 2020 13:55:39 +0000 (06:55 -0700)
committerTom Tromey <tromey@adacore.com>
Tue, 10 Nov 2020 20:12:59 +0000 (13:12 -0700)
commit6c51cf513d98adcf34a342c7e9d885a6c788cda8
tree5f10169af243f3e21b89680851f23b091b6397aa
parented1afd86668781159a131dc9c9c4a54a3b0a1e3a
Move include block to pathstuff.h

A recent commit caused pathstuff.cc to fail to compile on mingw, like:

../../binutils-gdb/gdbsupport/pathstuff.cc:324:1: error: no previous declaration for 'std::string find_gdb_home_config_file(const char*, _stati64*)' [-Werror=missing-declarations]

Some newly-added #includes were changing which "stat" was being seen
by the compiler.  This patch moves the includes to the header, so that
the declaration and definition now agree.

2020-11-10  Tom Tromey  <tromey@adacore.com>

PR build/26848:
* pathstuff.h: Move include block here...
* pathstuff.cc: ... from here.
gdbsupport/ChangeLog
gdbsupport/pathstuff.cc
gdbsupport/pathstuff.h