addHeaderIrLine static method
- String line
Adds a line to the LLVM IR header section.
Header lines are inserted at the beginning of the IR (before function definitions). This is used for:
- String constant declarations
- External function declarations (like printf, scanf)
- Global variable declarations
Parameters:
line
: The LLVM IR line to add to the header
Implementation
static addHeaderIrLine(String line) {
ir = "${line.trim()}\n$ir";
}