// LANGUAGE PREVIEW — compiles and runs in this browser playground.
// Runs on the pinned Rust/Wasm compiler; Java/LLVM parity is not claimed.
// Named modules; the single-file playground cannot import other files.
// `define module` introduces a named declaration; exports are `pub` members.
// Members without `pub` are private by default.
// A separate file could import this with:
//   import * as Arithmetic from "./arithmetic.atto";
// Project-root + imports require separate resolver conformance tests.

define module Arithmetic as
  pub fnc double(int value): int {
    return value * 2;
  }
end

define module Internal as
  fnc private_increment(int value): int {
    return value + 1;
  }
end

pub fnc main(): int {
  stdio.println(Arithmetic.double(21)); // 42
  return 0;
}
