[Issue 22988] New: Error: shift by -1 is outside the range `0..31`

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Apr 4 21:12:09 UTC 2022


https://issues.dlang.org/show_bug.cgi?id=22988

          Issue ID: 22988
           Summary: Error: shift by -1 is outside the range `0..31`
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: maxsamukha at gmail.com

enum a = 0;
enum b = a ? 1 << a - 1 : 0;

void main()
{
}

Error: shift by -1 is outside the range `0..31`

--


More information about the Digitalmars-d-bugs mailing list