alexcrichton transferred Issue #471:
Cranelift's clif files (example here) currently use
;
for line comments. This is somewhat common in assembler languages, and LLVM IR, but it's not always immediately obvious for people from other backgrounds.Using
//
would follow Cranelift's syntax for typesv0: i32
,-> i32
, and so on in taking syntactic queues from Rust where it makes sense to do so. (Related: should we changefunction
tofn
? That doesn't feel as important becausefunction
is more self-explanatory there, but it's worth considering.)
//
is two characters rather than;
's one, but my intuition is that little things we can do to make IR dumps easier to approach for people not already familiar with them will end up being valuable in a variety of contexts, more so than absolute conciseness.
Last updated: Nov 22 2024 at 16:03 UTC