Nix 2.26.3
Nix, the purely functional package manager; unstable internal interfaces
 
Loading...
Searching...
No Matches
file-path-impl.hh File Reference
#include <string>
#include <string_view>

Go to the source code of this file.

Classes

struct  nix::UnixPathTrait
 
struct  nix::WindowsPathTrait< CharT0 >
 

Typedefs

template<typename CharT>
using nix::OsPathTrait
 

Functions

template<class PathDict>
PathDict::String nix::canonPathInner (typename PathDict::StringView remaining, auto &&hookComponent)
 

Detailed Description

Pure (no IO) infrastructure just for defining other path types; should not be used directly outside of utilities.

Typedef Documentation

◆ OsPathTrait

template<typename CharT>
using nix::OsPathTrait
Initial value:
Definition file-path-impl.hh:20

Function Documentation

◆ canonPathInner()

template<class PathDict>
PathDict::String nix::canonPathInner ( typename PathDict::StringView remaining,
auto && hookComponent )

Core pure path canonicalization algorithm.

Parameters
hookComponentA callback which is passed two arguments, references to
  1. the result so far
  2. the remaining path to resolve

This is a chance to modify those two paths in arbitrary way, e.g. if "result" points to a symlink.