diff --git a/hilti/toolchain/src/compiler/driver.cc b/hilti/toolchain/src/compiler/driver.cc index 96417dd25..b52897fe1 100644 --- a/hilti/toolchain/src/compiler/driver.cc +++ b/hilti/toolchain/src/compiler/driver.cc @@ -573,8 +573,6 @@ Result Driver::addInput(const hilti::rt::filesystem::path& path) { (*unit)->setRequiresCompilation(); _addUnit(*unit); - - return Nothing(); } else if ( path.extension() == ".cc" || path.extension() == ".cxx" ) { @@ -612,11 +610,13 @@ Result Driver::addInput(const hilti::rt::filesystem::path& path) { } catch ( const hilti::rt::EnvironmentError& e ) { hilti::rt::fatalError(e.what()); } - - return Nothing(); } - return error("unsupported file type", path); + _processed_paths.insert(path); + + _processed_paths.insert(path.native()); + + return Nothing(); } Result Driver::addInput(declaration::module::UID uid) {