[all-commits] [llvm/llvm-project] a73714: [ObjectYAML] Use std::size (NFC)

kazutakahirata via All-commits all-commits at lists.llvm.org
Sat Nov 26 09:53:36 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a737146c9252e13233775cec3eeb6a09f9960437
      https://github.com/llvm/llvm-project/commit/a737146c9252e13233775cec3eeb6a09f9960437
  Author: Kazu Hirata <kazu at google.com>
  Date:   2022-11-26 (Sat, 26 Nov 2022)

  Changed paths:
    M llvm/lib/ObjectYAML/COFFEmitter.cpp

  Log Message:
  -----------
  [ObjectYAML] Use std::size (NFC)

std::size, introduced in C++17, allows us to directly obtain the
number of elements of an array.

This is part of an effort to migrate from llvm::Optional to
std::optional:

https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716




More information about the All-commits mailing list