<html>
<head>
<base href="http://llvm.org/bugs/" />
</head>
<body><span class="vcard"><a class="email" href="mailto:paul_robinson@playstation.sony.com" title="Paul Robinson <paul_robinson@playstation.sony.com>"> <span class="fn">Paul Robinson</span></a>
</span> changed
<a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED INVALID - enabling debuginfo with -g causes an undefined reference error at link time"
href="http://llvm.org/bugs/show_bug.cgi?id=19341">bug 19341</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Status</td>
<td>NEW
</td>
<td>RESOLVED
</td>
</tr>
<tr>
<td style="text-align:right;">Resolution</td>
<td>---
</td>
<td>INVALID
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED INVALID - enabling debuginfo with -g causes an undefined reference error at link time"
href="http://llvm.org/bugs/show_bug.cgi?id=19341#c5">Comment # 5</a>
on <a class="bz_bug_link
bz_status_RESOLVED bz_closed"
title="RESOLVED INVALID - enabling debuginfo with -g causes an undefined reference error at link time"
href="http://llvm.org/bugs/show_bug.cgi?id=19341">bug 19341</a>
from <span class="vcard"><a class="email" href="mailto:paul_robinson@playstation.sony.com" title="Paul Robinson <paul_robinson@playstation.sony.com>"> <span class="fn">Paul Robinson</span></a>
</span></b>
<pre>(In reply to <a href="show_bug.cgi?id=19341#c3">comment #3</a>)
<span class="quote">> I /believe/ the code has UB, no diagnostic required by ODR-using the
> variable but never defining it. Though I haven't looked at all the wording
> necessary to back that up with certainty.</span >
You are right, I was wrong.
The template-argument for these things is a constant expression (14.3.2p1).
ODR says a constant expression does not ODR-use the vars or functions named
in the expression, if the lvalue-to-rvalue conversion is immediately applied.
But lvalue-to-rvalue conversion is not in the list of conversions applied to
a template argument (14.3.2p5).
So it is legit for the debug info to assume a definition.
I'm closing this PR and withdrawing the patch.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>