<html><body><div style="color:#000; background-color:#fff; font-family:Courier New, courier, monaco, monospace, sans-serif;font-size:10pt"><div style="RIGHT: auto">Hi All,</div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto">I am using the  net20.c test case for pointer to member function to compile with clang.</div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto">This test generates wrong code when compiled using </div>
<div style="RIGHT: auto">'clang  -x c++ ...'</div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto"><A style="RIGHT: auto" href="https://llvm.org/viewvc/llvm-project/clang-tests/trunk/gcc-4_2-testsuite/src/g%2B%2B.old-deja/g%2B%2B.mike/net20.C?diff_format=c&view=markup&sortby=date">https://llvm.org/viewvc/llvm-project/clang-tests/trunk/gcc-4_2-testsuite/src/g%2B%2B.old-deja/g%2B%2B.mike/net20.C?diff_format=c&view=markup&sortby=date</A></div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto">The output it prints is:</div>
<div style="RIGHT: auto">define { i32, i32 } @_Z3feev() nounwind {<BR>entry:<BR>  %retval = alloca { i32, i32 }, align 4<BR>  br label %lab, !dbg !16</div>
<div style="RIGHT: auto">lab:                                      <VAR id=yui-ie-cursor></VAR>        ; preds = %lab, %entry<BR>  br label %lab, !dbg !18</div>
<div style="RIGHT: auto">return:                                           ; No predecessors!<BR>  %0 = load { i32, i32 }* %retval, !dbg !19<BR>  ret { i32, i32 } %0, !dbg !19<BR>}<BR></div>
<div style="RIGHT: auto">Here I see the function is returning '{i32,i32}' i.e. pointer to member function, which is not right, as it should  return 'void'.</div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto">Is clang not recognizing this correctly or am I making any mistake ?</div>
<div style="RIGHT: auto"> </div>
<div style="RIGHT: auto">Thanks & Regards,</div>
<div style="RIGHT: auto">Pankaj</div></div></body></html>