[all-commits] [llvm/llvm-project] fef260: [Sema] Use the proper cast for a fixed bool enum.

mordante via All-commits all-commits at lists.llvm.org
Sun Aug 16 09:44:49 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: fef26071240711e8f7305715b5f22cfc7ad04bfe
      https://github.com/llvm/llvm-project/commit/fef26071240711e8f7305715b5f22cfc7ad04bfe
  Author: Mark de Wever <koraq at xs4all.nl>
  Date:   2020-08-16 (Sun, 16 Aug 2020)

  Changed paths:
    M clang/lib/Sema/SemaCast.cpp
    M clang/test/CXX/drs/dr23xx.cpp
    A clang/test/CodeGen/enum-bool.cpp

  Log Message:
  -----------
  [Sema] Use the proper cast for a fixed bool enum.

When casting an enumerate with a fixed bool type the casting should use
an IntegralToBoolean instead of an IntegralCast as is required per Core
Issue 2338.

Fixes PR47055: Incorrect codegen for enum with bool underlying type

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




More information about the All-commits mailing list