public function __construct()

in src/CodegenFile.hack [63:77]


  public function __construct(
    private IHackCodegenConfig $config,
    string $file_name,
  ) {
    $root = $config->getRootDir();
    if (!Str\starts_with($file_name, '/')) {
      $this->relativeFileName = $file_name;
      $file_name = $root.'/'.$file_name;
    } else if (Str\starts_with($file_name, $root)) {
      $this->relativeFileName = Str\slice($file_name, Str\length($root) + 1);
    } else {
      $this->relativeFileName = $file_name;
    }
    $this->fileName = $file_name;
  }