http://llvm.org/bugs/show_bug.cgi?id=21530

            Bug ID: 21530
           Summary: Detect integer demotions in UBSan
           Product: clang
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected], [email protected]
    Classification: Unclassified

UBSan currently does not check integer demotions i.e. casts from wider integer
type to a smaller one. This is indeed not undefined behavior but rather
implementation defined. Still, loosing higher bits when downcasting ints to
chars is a constant source of bugs and it would be nice to have an optional
check for it (like we already have for float-cast-overflow).

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to