[lld] r248715 - [ELF2] Add --sysroot command line switch

Rafael EspĂ­ndola via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 28 11:09:17 PDT 2015


> +  if (Dir.startswith("=")) {
> +    Path.assign(Config->Sysroot);
> +    sys::path::append(Path, Dir.substr(1), File);
> +  } else {
> +    Path.assign(Dir);
> +    sys::path::append(Path, File);
> +  }

Nit, this is the same as the simpler:

  if (Dir.startswith("=")) {
    Path.assign(Config->Sysroot);
    Dir = Dir.substr(1);
  }
  sys::path::append(Path, Dir, File);

no?

Cheers,
Rafael


More information about the llvm-commits mailing list