<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif; ">
<div>I've run into this bug (<a href="http://llvm.org/bugs/show_bug.cgi?id=13517" target="_blank" rel="nofollow" style="cursor: pointer; color: rgb(59, 89, 152); text-decoration: initial; font-family: 'lucida grande', tahoma, verdana, arial, sans-serif; font-size: 11px; line-height: 14px; text-align: left; white-space: pre-wrap; background-color: rgb(237, 239, 244); ">http://llvm.org/bugs/show_bug.cgi?id=13517</a>),
 which seems to be related to the fixme in SemaType.cpp on line 2691.</div>
<div><br>
</div>
<div>I talked to Chandler Carruth, and he suggested that I look at Sema::MergeFunctionDecl. Moving all the logic there (like that fixme seems to imply) didn't seem to work, because then functions that have a single definition don't get const added to them. </div>
<div><br>
</div>
<div>Instead, I put logic there to remove the errant constness from static functions. I've attached a patch. Please let me know if you have any comments, as I've never contributed to the Clang codebase before.</div>
<div><br>
</div>
<div>Thanks!</div>
<div>Christopher Berner</div>
</body>
</html>