libmir / mir-cpuid

BetterC CPU Identification Routines
http://mir-cpuid.libmir.org
26 stars 8 forks source link

gdc build error: mir-cpuid/1.2.11/mir-cpuid/source/cpuid/x86_any.d:606:18: error: ‘a’ must be surrounded by parentheses #47

Open mw66 opened 2 weeks ago

mw66 commented 2 weeks ago

gdc (GCC) 14.1.0

mir-cpuid/1.2.11/mir-cpuid/source/cpuid/x86_any.d:606:18: error: ‘a’ must be surrounded by parentheses
  606 |             "=a" a,
      |                  ^
mw66 commented 2 weeks ago

adding parentheses make gdc build:

    {                                                                                                                                                                                                       
        "cpuid" :                                                                                                                                                                                           
            "=a" (a),                                                                                                                                                                                       
            "=b" (b),                                                                                                                                                                                       
            "=c" (c),                                                                                                                                                                                       
            "=d" (d),                                                                                                                                                                                       
            : "a" (eax), "c" (ecx);                                                                                                                                                                         
    }