[all-commits] [llvm/llvm-project] 42ffba: Add a clarifying a comment on CastInst::isNoopCast

Philip Reames via All-commits all-commits at lists.llvm.org
Wed Oct 7 12:17:32 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 42ffba051894a66cf6d7b9a357e765a392d983ed
      https://github.com/llvm/llvm-project/commit/42ffba051894a66cf6d7b9a357e765a392d983ed
  Author: Philip Reames <listmail at philipreames.com>
  Date:   2020-10-07 (Wed, 07 Oct 2020)

  Changed paths:
    M llvm/include/llvm/IR/InstrTypes.h

  Log Message:
  -----------
  Add a clarifying a comment on CastInst::isNoopCast

I made exactly the mistake described, so document the precondition.  It would be better to have an assert, but there is (currently) no "castIsValid" with purely type arguments.




More information about the All-commits mailing list