[all-commits] [llvm/llvm-project] dfa971: [GISel] Fix dead code warning in getRuleRangeForId...

Simon Pilgrim via All-commits all-commits at lists.llvm.org
Sat Feb 19 11:44:27 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: dfa9716dd7a63943ba887bc002d726bffc3490ef
      https://github.com/llvm/llvm-project/commit/dfa9716dd7a63943ba887bc002d726bffc3490ef
  Author: Simon Pilgrim <llvm-dev at redking.me.uk>
  Date:   2022-02-19 (Sat, 19 Feb 2022)

  Changed paths:
    M llvm/utils/TableGen/GICombinerEmitter.cpp

  Log Message:
  -----------
  [GISel] Fix dead code warning in getRuleRangeForIdentifier emitted method. NFC.

Break the if-else chain as every block returns, and remove the return at the end of the function as the else block means this was never hit




More information about the All-commits mailing list