<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/121792>121792</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[TableGen] Track location for Inits
</td>
</tr>
<tr>
<th>Labels</th>
<td>
tablegen
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
jurahul
</td>
</tr>
</table>
<pre>
TableGen's `Init` and subclasses do not track locations. This issue is to enhance the Init to also track its location. Currently, the Init nodes are uniqued using a FoldingSet, so we can either do away with that or add an indirection so that an `Init` node is its location + a pointer to the uniqued "contents".
Once locations are tracked for `Init`s, we also need to enhance the error reporting to use these locations.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJxckstu3DwMhZ9G3hAxZPk2s_AiF8yPf9VF8wK0xdhKFWkqUhnk7Qu56WTalQELhzzf4UFmtwaiSfUPqn-qMMsW0_SaE27ZV3O0H9Mzzp7-o6DMyKAG_X9wogYNGCxwnhePzMRgI4QoIAmXH-DjguJi4BqeN8fgmDOBY5AIFDYMC4FsBGVW-Yee46fUCV_lNTzmlCiI_1Dm8UsRoiUGTAQ5uJ-ZLGR2YQWEU_TWhfU7SRFwhAvBggHIyUapmMQLfsDFyQayoUBMgNYCBnDBukRL2VuE-yuGW-KytkDcWgRlHgDhHF0QSoWluPxjSxmzxCAUhJUxtdL3St9_K_TXhHaMHZ0svMR0s5ALw4V-pxOI7L_xUUoxQaJzTFL4JULm_Ynp9gaVnVp7bI9Y0dSM7dActG77apt0R_iyDDON_aLb9jB2TYfL0tv2cLTD2FZuMtr0utFDMzRt39XdAXuLo24a3duRZtVpekPna-_f3-qY1mq_9dSYZjyayuNMnvd6GSOlSWtpkillS1PR3M15ZdVp71j4a4o48Xstr_Xrn-D5r3LtaZWouMrJT5vImVV7r8xJmdPqZMtzvcQ3ZU5l6ufn7pziKy2izGk3ysqcPr2-T-ZXAAAA__-P3gZ0">