/// Returns its argument unchanged.
fn id(x: i32) -> i32 {
    return x;
}

/// Returns the argument plus one.
fn inc(x: i32) -> i32 {
    return x + 1;
}

/// Returns the sum of two integers.
fn add(a: i32, b: i32) -> i32 {
    return a + b;
}

/// Performs no observable work.
fn doNothing() {}

/// Calls a simple helper and returns the result.
fn callSimple(x: i32) -> i32 {
    return id(x);
}

/// Calls nested helpers to build the final result.
fn callNested(x: i32, y: i32) -> i32 {
    return add(inc(x), inc(y));
}

/// Calls a no-result function and then returns a constant.
fn callVoid() -> i32 {
    doNothing();
    return 1;
}

/// Calls a function for its side effects and ignores the result.
fn callAndIgnore() -> i32 {
    id(5);
    return 0;
}
