I’m struggling to find precedents besides RedCarpet’s usage in Jekyll, but several tools I’ve used have produced an attribute that identifies the language of the code block being rendered (i.e., data-lang="<LANGUAGE>", class="language-<LANGUAGE>"). This can offer some neat styling tweaks with CSS! Here’s an example of how that might look:
I’d prefer to have it be available in all cases – I specifically was hoping for language-specific decorations around rendered code blocks – but I understand that I’m not necessarily representative of others’ use cases.