[Issue 21628] New: The padding bits of bitfields could be calculated automatically
    d-bugmail at puremagic.com 
    d-bugmail at puremagic.com
       
    Thu Feb 11 07:22:30 UTC 2021
    
    
  
https://issues.dlang.org/show_bug.cgi?id=21628
          Issue ID: 21628
           Summary: The padding bits of bitfields could be calculated
                    automatically
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: phobos
          Assignee: nobody at puremagic.com
          Reporter: bugzilla at bernis-buecher.de
struct A
{
    mixin(bitfields!(
        bool, "flag1",    1,
        bool, "flag2",    1));
}
could be treated as if it were
struct A
{
    mixin(bitfields!(
        bool, "flag1",    1,
        bool, "flag2",    1,
        uint, "",         6));
}
--
    
    
More information about the Digitalmars-d-bugs
mailing list