@@ -1019,8 +1019,9 @@ struct Preprocessor::Private {
10191019 Resolve (const Resolve &other) = delete ;
10201020 auto operator =(const Resolve &other) -> Resolve & = delete ;
10211021
1022- Resolve (const Private *d, bool next)
1023- : d(d), wantNextInlude(next), currentPaths{{d->currentPath_ }} {}
1022+ Resolve (const Private *d, bool next) : d(d), wantNextInlude(next) {
1023+ currentPaths[0 ] = d->currentPath_ .string ();
1024+ }
10241025
10251026 using SearchPaths = std::vector<std::span<const std::string>>;
10261027
@@ -1050,15 +1051,15 @@ struct Preprocessor::Private {
10501051
10511052 [[nodiscard]] auto userHeaderSearchPaths () -> SearchPaths {
10521053 std::vector<std::span<const std::string>> paths;
1053- paths.push_back (currentPaths);
1054- paths.push_back (d->quoteIncludePaths_ );
1055- paths.push_back (d->systemIncludePaths_ );
1054+ paths.push_back (std::span< const std::string>( currentPaths) );
1055+ paths.push_back (std::span< const std::string>( d->quoteIncludePaths_ ) );
1056+ paths.push_back (std::span< const std::string>( d->systemIncludePaths_ ) );
10561057 return paths;
10571058 }
10581059
10591060 [[nodiscard]] auto systemHeaderSearchPaths () -> SearchPaths {
10601061 std::vector<std::span<const std::string>> paths;
1061- paths.push_back (d->systemIncludePaths_ );
1062+ paths.push_back (std::span< const std::string>( d->systemIncludePaths_ ) );
10621063 return paths;
10631064 }
10641065
0 commit comments