[all-commits] [llvm/llvm-project] 8f89c0: [lld-macho][nfc] Remove unnecessary use of Optiona...

Vy Nguyen via All-commits all-commits at lists.llvm.org
Tue Jun 1 15:35:58 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8f89c054afa115e4e45dbc76f7efa2e7f485d227
      https://github.com/llvm/llvm-project/commit/8f89c054afa115e4e45dbc76f7efa2e7f485d227
  Author: Vy Nguyen <vyng at google.com>
  Date:   2021-06-01 (Tue, 01 Jun 2021)

  Changed paths:
    M lld/MachO/Driver.cpp
    M lld/MachO/Driver.h
    M lld/MachO/DriverUtils.cpp
    M lld/MachO/InputFiles.cpp

  Log Message:
  -----------
  [lld-macho][nfc] Remove unnecessary use of Optional<T*>

In all of these cases, the functions could simply return a nullptr instead of {}.
There is no case where Optional<nullptr> has a special meaning.

Differential Revision: https://reviews.llvm.org/D103489




More information about the All-commits mailing list