<dt>Status</dt><dd><em>Use site of an external type family — the equation isn't in this project's dumps, so the right-hand side can't be resolved here.</em></dd>
</dl>`;
}
- const rhs = escape(renderArg(fi.fiRhs, fi.fiTyVars));
const tvs = fi.fiTyVars.length === 0 ? '<dd><em>none</em></dd>' :
`<dd><ul>${fi.fiTyVars.map(v =>
`<li>${escape(v.tvName)}<span style="color:#888"> :: ${escape(v.tvKind)}</span></li>`).join('')}</ul></dd>`;
const src = renderDefinedAt(fi.fiSrc, fi.fiDefinedIn || fi.fiFamily.qnPackage);
+ // For data fam-instances we *don't* show a "Right-hand side" row.
+ // GHC's representation is the synthetic R: TyCon (`R:CrateInt`),
+ // and after our R: rewrite it's the abstract @FamilyApp Family
+ // [args]@ form — structurally equal to the LHS, so labelling it
+ // "Right-hand side" was actively misleading. Show a brief
+ // explanatory note instead.
+ const rhsEntry = fi.fiIsData
+ ? `<dt>Kind</dt><dd><em>Data instance — the right-hand side is a synthetic GHC-internal data constructor and isn't shown.</em></dd>`
+ : `<dt>Right-hand side</dt><dd>${escape(renderArg(fi.fiRhs, fi.fiTyVars))}</dd>`;
return `
<h2>${head}</h2>
<p class="pkgmod">${escape(fi.fiFamily.qnPackage)} · ${escape(fi.fiFamily.qnModule)}</p>
<dl>
${renderDocSection(fi.fiDoc)}
- <dt>Right-hand side</dt><dd>${rhs}</dd>
+ ${rhsEntry}
<dt>Type variables</dt>${tvs}
<dt>Defined at</dt>${src}
</dl>`;