Stdlib module io.vitl

This page is a wiki-style reference for one concrete stdlib file. It explains what the file owns, where it fits in the family, and how to decide whether this is the right surface to depend on.

Visual portrait of io.vitl
Wiki-style portrait for io.vitl.

Family: io

Kind: public stdlib surface

Page style: this reference follows the same “encyclopedic card + portrait + usage contract” logic as the keyword pages, but for stdlib modules.

Summary

Overview

FieldValue
Pathio.vitl
Familyio
Kindpublic stdlib surface
Line count1136
Declared procedures132
Declared forms/picks12

`io.vitl` is a public stdlib surface inside the `io` family. It should be read as one focused slice of the broader family responsibility: File, buffer, stream, stdio, and host-runtime access helpers.

Purpose

This file should be chosen because of responsibility, not because its name “sounds close enough”. Inside the io family, it carries one focused part of the contract and keeps that responsibility separate from neighboring concerns.

  • A manifest is loaded through `io`, parsed elsewhere, validated elsewhere, and only then emitted back through `io`.
  • A stdio helper should explain where user-facing text enters the flow.

Taxonomy

Think of this page as a generated encyclopedia entry rather than a hand-written tutorial. The goal is to show what kind of module this is, how dense it is, and what reading strategy makes sense before depending on it.

  • Large algorithm surface: this file exposes many procedures and likely acts as a domain toolkit rather than a single thin wrapper.
  • Owns domain vocabulary: the module declares data shapes in addition to executable helpers, so its types are part of the contract.
  • Has tuning constants: part of the module behavior is controlled by named constants that document default precision, limits, or policy.
  • Minimal top-level dependencies: the module reads as mostly self-contained from its opening declarations.
  • Explicit export surface: the file ends with visible export declarations instead of relying only on implicit namespace discovery.

Implementation profile

This profile is inferred directly from the source text. It does not replace reading the file, but it tells you quickly whether the module is mostly declarative, loop-heavy, branch-heavy, or organized around many small exits.

SignalCountWhat it suggests
if66Branching density and local decision-making.
while2Loop-heavy or iterative implementation style.
for0Collection-style traversal at source level.
match0Variant-driven branching or grammar-style decoding.
let37Local state and intermediate value density.
give182Number of explicit exit points and result shaping.

Top-level API inventory

SurfaceItems
Proceduresio_ok, io_name, io_version, io_modules, io_module_count, io_manifest, io_health, io_summary, io_failed, null_file, stdin_file, stdout_file
FormsIoResult, File, FileStat, DirEntry, Buffer, TextReader, TextWriter, PathInfo, IOLibraryManifest, IOLibraryHealth, IOLibrarySummary
PicksIoStatus
ConstantsIO_VERSION, EOF, NULL_FD, SEEK_SET, SEEK_CUR, SEEK_END, IO_READ, IO_WRITE, IO_APPEND, IO_CREATE, IO_TRUNC, IO_BINARY
Exports*

Imported surfaces

This file does not advertise a top-level `use` surface in its opening declarations. That often means it is either self-contained or an aggregation layer.

Position in family

This file is module 1 of 8 in the io family when ordered by path. By procedure count it ranks 1, and by line count it ranks 1. Those ranks are useful as rough signals of breadth, not as quality judgments.

Declaration map

The declaration map turns raw source into a scan-friendly catalog. It is useful when the file is large enough that a reader wants to orient by kinds of surfaces first.

LineNameKindRole
1vitte/stdlib/iospaceDeclares the namespace that anchors this file in the stdlib tree.
11IO_VERSIONconstDefines a named constant reused across the module.
13EOFconstDefines a named constant reused across the module.
14NULL_FDconstDefines a named constant reused across the module.
16SEEK_SETconstDefines a named constant reused across the module.
17SEEK_CURconstDefines a named constant reused across the module.
18SEEK_ENDconstDefines a named constant reused across the module.
20IO_READconstDefines a named constant reused across the module.
21IO_WRITEconstDefines a named constant reused across the module.
22IO_APPENDconstDefines a named constant reused across the module.
23IO_CREATEconstDefines a named constant reused across the module.
24IO_TRUNCconstDefines a named constant reused across the module.
25IO_BINARYconstDefines a named constant reused across the module.
26IO_TEXTconstDefines a named constant reused across the module.
28READconstDefines a named constant reused across the module.
29WRITEconstDefines a named constant reused across the module.
30APPENDconstDefines a named constant reused across the module.
31READ_WRITEconstDefines a named constant reused across the module.
32WRITE_READconstDefines a named constant reused across the module.
33APPEND_READconstDefines a named constant reused across the module.
34READ_BINARYconstDefines a named constant reused across the module.
35WRITE_BINARYconstDefines a named constant reused across the module.
36APPEND_BINARYconstDefines a named constant reused across the module.
38_IOFBFconstDefines a named constant reused across the module.
39_IOLBFconstDefines a named constant reused across the module.
40_IONBFconstDefines a named constant reused across the module.
42PATH_SEPconstDefines a named constant reused across the module.
43EXT_SEPconstDefines a named constant reused across the module.
44MAX_PATHconstDefines a bound or precision constant that shapes runtime behavior.
46IoStatuspickIntroduces a tagged variant type used to model distinct outcomes.
59IoResultformIntroduces a structured data shape that other procedures can exchange.
65FileformIntroduces a structured data shape that other procedures can exchange.
78FileStatformIntroduces a structured data shape that other procedures can exchange.
91DirEntryformIntroduces a structured data shape that other procedures can exchange.
100BufferformIntroduces a structured data shape that other procedures can exchange.
107TextReaderformIntroduces a structured data shape that other procedures can exchange.
113TextWriterformIntroduces a structured data shape that other procedures can exchange.
118PathInfoformIntroduces a structured data shape that other procedures can exchange.
126IOLibraryManifestformIntroduces a structured data shape that other procedures can exchange.
133IOLibraryHealthformIntroduces a structured data shape that other procedures can exchange.
142IOLibrarySummaryformIntroduces a structured data shape that other procedures can exchange.
147io_okprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
155io_nameprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
159io_versionprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
163io_modulesprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
175io_module_countprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
179io_manifestprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
188io_healthprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
199io_summaryprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
206io_failedprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
214null_fileprocOwns byte movement or host I/O interaction.
229stdin_fileprocOwns byte movement or host I/O interaction.
244stdout_fileprocOwns byte movement or host I/O interaction.
259stderr_fileprocOwns byte movement or host I/O interaction.
274file_is_openprocOwns byte movement or host I/O interaction.
278file_can_readprocOwns byte movement or host I/O interaction.
282file_can_writeprocOwns byte movement or host I/O interaction.
286mode_readableprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
308mode_writableprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
333mode_appendprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
346mode_binaryprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
350fopenprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
369freopenprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
374fcloseprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
382fflushprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
390ferrorprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
398feofprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
402clearerrprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
409rewindprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
417fseekprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
439ftellprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
443fgetposprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
447fsetposprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
453freadprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
461fwriteprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
469fgetcprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
477getcprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
481getcharprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
485fputcprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
493putcprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
497putcharprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
501ungetcprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
509fgetsprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
521getsprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
525fputsprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
533putsprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
539printprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
543printlnprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
547eprintprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
551eprintlnprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
556emit_stringprocTurns internal values into a transport or textual representation.
560print_intprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
564println_intprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
569print_floatprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
573println_floatprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
578print_boolprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
586println_boolprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
591printfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
597fprintfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
603sprintfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
607snprintfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
617scanfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
621fscanfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
629sscanfprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
637read_lineprocOwns byte movement or host I/O interaction.
641read_stringprocOwns byte movement or host I/O interaction.
645read_intprocOwns byte movement or host I/O interaction.
649read_floatprocOwns byte movement or host I/O interaction.
653read_boolprocOwns byte movement or host I/O interaction.
663read_all_stdinprocOwns byte movement or host I/O interaction.
667read_fileprocOwns byte movement or host I/O interaction.
678read_file_bytesprocOwns byte movement or host I/O interaction.
682read_linesprocOwns byte movement or host I/O interaction.
687write_fileprocOwns byte movement or host I/O interaction.
699write_file_bytesprocOwns byte movement or host I/O interaction.
711append_fileprocOwns byte movement or host I/O interaction.
723copy_fileprocOwns byte movement or host I/O interaction.
728move_fileprocOwns byte movement or host I/O interaction.
738removeprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
746renameprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
754file_existsprocOwns byte movement or host I/O interaction.
758is_fileprocOwns byte movement or host I/O interaction.
762is_dirprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
766is_symlinkprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
770file_sizeprocOwns byte movement or host I/O interaction.
774statprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
789mkdirprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
797mkdir_allprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
805rmdirprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
813list_dirprocOwns a concrete data shape or the operations that maintain it.
817read_dir_namesprocOwns byte movement or host I/O interaction.
830touchprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
838tmpfileprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
842tmpnamprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
850basenameprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
855dirnameprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
860extensionprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
865stemprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
870path_joinprocOwns path semantics, traversal, or normalization.
886path_join3procOwns path semantics, traversal, or normalization.
890path_normalizeprocOwns path semantics, traversal, or normalization.
894path_is_absoluteprocOwns path semantics, traversal, or normalization.
898path_is_relativeprocOwns path semantics, traversal, or normalization.
902path_parseprocTransforms an input representation into a structured internal value.
917buffer_newprocOwns byte movement or host I/O interaction.
926buffer_from_bytesprocOwns byte movement or host I/O interaction.
935buffer_clearprocOwns byte movement or host I/O interaction.
943buffer_remainingprocOwns byte movement or host I/O interaction.
951buffer_is_emptyprocOwns byte movement or host I/O interaction.
955reader_newprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
963writer_newprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
970reader_read_lineprocOwns byte movement or host I/O interaction.
974writer_writeprocOwns byte movement or host I/O interaction.
985writer_writelnprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
990perrorprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
994strerrorprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1006setbufprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1014setvbufprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1026format_applyprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1048to_string_i64procRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1052to_string_f64procRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1056parse_i64procTransforms an input representation into a structured internal value.
1060parse_f64procTransforms an input representation into a structured internal value.
1064split_linesprocOwns path semantics, traversal, or normalization.
1068string_containsprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1072string_starts_withprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1076string_ends_withprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1080string_sliceprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1084string_char_atprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1088io_readyprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1092io_domainsprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1105library_metaprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.
1109io_selftestprocRepresents one top-level surface in the file contract and should be read as part of the module boundary.

The table is exhaustive for top-level declarations of the selected kinds. This file declares 173 matching surfaces.

Representative signatures

These signatures are shown in source order so the page keeps the feel of a reference manual, not just a keyword cloud.

  • const IO_VERSION: string = "1.0.0" (line 11)
  • const EOF: int = -1 (line 13)
  • const NULL_FD: int = -1 (line 14)
  • const SEEK_SET: int = 0 (line 16)
  • const SEEK_CUR: int = 1 (line 17)
  • const SEEK_END: int = 2 (line 18)
  • const IO_READ: int = 1 (line 20)
  • const IO_WRITE: int = 2 (line 21)
  • const IO_APPEND: int = 4 (line 22)
  • const IO_CREATE: int = 8 (line 23)
  • const IO_TRUNC: int = 16 (line 24)
  • const IO_BINARY: int = 32 (line 25)
  • const IO_TEXT: int = 64 (line 26)
  • const READ: string = "r" (line 28)
  • const WRITE: string = "w" (line 29)
  • const APPEND: string = "a" (line 30)
  • const READ_WRITE: string = "r+" (line 31)
  • const WRITE_READ: string = "w+" (line 32)

The list is intentionally capped here; the source file declares 172 matching signatures in total.

How to use this module

Start by reading the file as an ownership boundary. Ask three questions: what enters this module, what stable types or procedures it exports, and what adjacent module should stay outside of it.

  1. Read space and top-level imports first so the ownership boundary of io.vitl is explicit.
  2. Scan constants before procedures; they often encode precision, limits, or policy assumptions that explain later behavior.
  3. Read declared forms and picks before algorithms so the data vocabulary is stable in your head.
  4. Traverse procedures in source order; the early helpers usually explain the naming and numeric conventions used later.
  5. Use the source landmarks section below as a table of contents when the file is large.

User example

This example is generated from the actual stdlib module surface. Its job is not to be the smallest snippet possible; its job is to show a realistic consumer-shaped file that exercises the module and mirrors the language keywords the module itself relies on.

space demo/io
const SAMPLE_LABEL: string = "demo"
form UserReport {
  label: string,
  ready: bool
}
pick UserOutcome {
  case Ready(message: string)
  case Empty(reason: string)
}
proc run_example() -> UserOutcome {
  let entries = io_modules()
  let ready: bool = file_is_open(File())
  let failed: bool = false
  let stable: bool = ready and true
  let fallback: bool = ready or false
  let idx: int = 0
  let count: int = 0
  while idx < entries.len {
    set count = count + 1
    set idx = idx + 1
  }
  if not ready {
    give UserOutcome.Empty("module not ready")
  } else {
    give UserOutcome.Ready("ok")
  }
  let copies: f64 = 1 as f64
}
export run_example

Keyword coverage

This table makes the “all keywords of the module” requirement auditable. It compares the detected Vitte keywords in the source file with the generated consumer example above.

KeywordPresent in module sourceUsed in generated user example
spaceyesyes
constyesyes
formyesyes
pickyesyes
caseyesyes
procyesyes
letyesyes
setyesyes
ifyesyes
elseyesyes
whileyesyes
giveyesyes
exportyesyes
trueyesyes
falseyesyes
andyesyes
oryesyes
notyesyes
asyesyes

The generated snippet exercises every detected Vitte keyword used by this module.

Source shape

space vitte/stdlib/io
export *
const IO_VERSION: string = "1.0.0"
const EOF: int = -1
const NULL_FD: int = -1
const SEEK_SET: int = 0
const SEEK_CUR: int = 1
const SEEK_END: int = 2
const IO_READ: int = 1
const IO_WRITE: int = 2

The excerpt is not meant to replace the file. It exists to make the module recognizable at first glance, the same way a Wikipedia infobox helps the reader orient before reading the whole article.

Source landmarks

Large files are easier to retain when they have visible landmarks. When the source contains explicit section banners, they are surfaced here; otherwise the first major declarations are used as anchors.

  • Vitte I/O Library / C-like stdio + POSIX-like file/path utilities / current Vitte syntax: { }

Source organization

When a file carries its own internal chaptering, those chapters usually reveal the intended reading order better than a flat symbol list. This section reconstructs that organization from the source itself.

Opening declarations

Top-level items: 2. Procedures: 0. Data surfaces: 0. Constants: 0.

First visible names: vitte/stdlib/io, *

Vitte I/O Library / C-like stdio + POSIX-like file/path utilities / current Vitte syntax: { }

Top-level items: 172. Procedures: 132. Data surfaces: 12. Constants: 28.

First visible names: IO_VERSION, EOF, NULL_FD, SEEK_SET, SEEK_CUR, SEEK_END, IO_READ, IO_WRITE, IO_APPEND, IO_CREATE

Complete API catalog

This catalog is the exhaustive file-level index for the module. It is intentionally closer to a generated encyclopedia appendix than to a tutorial summary.

Constants

LineNameSignatureRole
11IO_VERSIONconst IO_VERSION: string = "1.0.0"Defines a named constant reused across the module.
13EOFconst EOF: int = -1Defines a named constant reused across the module.
14NULL_FDconst NULL_FD: int = -1Defines a named constant reused across the module.
16SEEK_SETconst SEEK_SET: int = 0Defines a named constant reused across the module.
17SEEK_CURconst SEEK_CUR: int = 1Defines a named constant reused across the module.
18SEEK_ENDconst SEEK_END: int = 2Defines a named constant reused across the module.
20IO_READconst IO_READ: int = 1Defines a named constant reused across the module.
21IO_WRITEconst IO_WRITE: int = 2Defines a named constant reused across the module.
22IO_APPENDconst IO_APPEND: int = 4Defines a named constant reused across the module.
23IO_CREATEconst IO_CREATE: int = 8Defines a named constant reused across the module.
24IO_TRUNCconst IO_TRUNC: int = 16Defines a named constant reused across the module.
25IO_BINARYconst IO_BINARY: int = 32Defines a named constant reused across the module.
26IO_TEXTconst IO_TEXT: int = 64Defines a named constant reused across the module.
28READconst READ: string = "r"Defines a named constant reused across the module.
29WRITEconst WRITE: string = "w"Defines a named constant reused across the module.
30APPENDconst APPEND: string = "a"Defines a named constant reused across the module.
31READ_WRITEconst READ_WRITE: string = "r+"Defines a named constant reused across the module.
32WRITE_READconst WRITE_READ: string = "w+"Defines a named constant reused across the module.
33APPEND_READconst APPEND_READ: string = "a+"Defines a named constant reused across the module.
34READ_BINARYconst READ_BINARY: string = "rb"Defines a named constant reused across the module.
35WRITE_BINARYconst WRITE_BINARY: string = "wb"Defines a named constant reused across the module.
36APPEND_BINARYconst APPEND_BINARY: string = "ab"Defines a named constant reused across the module.
38_IOFBFconst _IOFBF: i32 = 0Defines a named constant reused across the module.
39_IOLBFconst _IOLBF: i32 = 1Defines a named constant reused across the module.
40_IONBFconst _IONBF: i32 = 2Defines a named constant reused across the module.
42PATH_SEPconst PATH_SEP: string = "/"Defines a named constant reused across the module.
43EXT_SEPconst EXT_SEP: string = "."Defines a named constant reused across the module.
44MAX_PATHconst MAX_PATH: int = 4096Defines a bound or precision constant that shapes runtime behavior.

Data surfaces

LineNameSignatureRole
46IoStatuspick IoStatus {Introduces a tagged variant type used to model distinct outcomes.
59IoResultform IoResult {Introduces a structured data shape that other procedures can exchange.
65Fileform File {Introduces a structured data shape that other procedures can exchange.
78FileStatform FileStat {Introduces a structured data shape that other procedures can exchange.
91DirEntryform DirEntry {Introduces a structured data shape that other procedures can exchange.
100Bufferform Buffer {Introduces a structured data shape that other procedures can exchange.
107TextReaderform TextReader {Introduces a structured data shape that other procedures can exchange.
113TextWriterform TextWriter {Introduces a structured data shape that other procedures can exchange.
118PathInfoform PathInfo {Introduces a structured data shape that other procedures can exchange.
126IOLibraryManifestform IOLibraryManifest {Introduces a structured data shape that other procedures can exchange.
133IOLibraryHealthform IOLibraryHealth {Introduces a structured data shape that other procedures can exchange.
142IOLibrarySummaryform IOLibrarySummary {Introduces a structured data shape that other procedures can exchange.

Procedures

LineNameSignatureRole
147io_okproc io_ok(message: string) -> IoResult {Represents one top-level surface in the file contract and should be read as part of the module boundary.
155io_nameproc io_name() -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
159io_versionproc io_version() -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
163io_modulesproc io_modules() -> [string] {Represents one top-level surface in the file contract and should be read as part of the module boundary.
175io_module_countproc io_module_count() -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
179io_manifestproc io_manifest() -> IOLibraryManifest {Represents one top-level surface in the file contract and should be read as part of the module boundary.
188io_healthproc io_health() -> IOLibraryHealth {Represents one top-level surface in the file contract and should be read as part of the module boundary.
199io_summaryproc io_summary() -> IOLibrarySummary {Represents one top-level surface in the file contract and should be read as part of the module boundary.
206io_failedproc io_failed(code: int, message: string) -> IoResult {Represents one top-level surface in the file contract and should be read as part of the module boundary.
214null_fileproc null_file() -> File {Owns byte movement or host I/O interaction.
229stdin_fileproc stdin_file() -> File {Owns byte movement or host I/O interaction.
244stdout_fileproc stdout_file() -> File {Owns byte movement or host I/O interaction.
259stderr_fileproc stderr_file() -> File {Owns byte movement or host I/O interaction.
274file_is_openproc file_is_open(f: File) -> bool {Owns byte movement or host I/O interaction.
278file_can_readproc file_can_read(f: File) -> bool {Owns byte movement or host I/O interaction.
282file_can_writeproc file_can_write(f: File) -> bool {Owns byte movement or host I/O interaction.
286mode_readableproc mode_readable(mode: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
308mode_writableproc mode_writable(mode: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
333mode_appendproc mode_append(mode: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
346mode_binaryproc mode_binary(mode: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
350fopenproc fopen(path: string, mode: string) -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
369freopenproc freopen(path: string, mode: string, stream: File) -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
374fcloseproc fclose(f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
382fflushproc fflush(f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
390ferrorproc ferror(f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
398feofproc feof(f: File) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
402clearerrproc clearerr(f: File) -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
409rewindproc rewind(f: File) -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
417fseekproc fseek(f: File, offset: i64, whence: int) -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
439ftellproc ftell(f: File) -> i64 {Represents one top-level surface in the file contract and should be read as part of the module boundary.
443fgetposproc fgetpos(f: File) -> i64 {Represents one top-level surface in the file contract and should be read as part of the module boundary.
447fsetposproc fsetpos(f: File, pos: i64) -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
453freadproc fread(buffer: bytes, size: usize, count: usize, f: File) -> usize {Represents one top-level surface in the file contract and should be read as part of the module boundary.
461fwriteproc fwrite(buffer: bytes, size: usize, count: usize, f: File) -> usize {Represents one top-level surface in the file contract and should be read as part of the module boundary.
469fgetcproc fgetc(f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
477getcproc getc(f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
481getcharproc getchar() -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
485fputcproc fputc(c: int, f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
493putcproc putc(c: int, f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
497putcharproc putchar(c: int) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
501ungetcproc ungetc(c: int, f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
509fgetsproc fgets(size: int, f: File) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
521getsproc gets() -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
525fputsproc fputs(s: string, f: File) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
533putsproc puts(s: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
539printproc print(s: string) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
543printlnproc println(s: string) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
547eprintproc eprint(s: string) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
551eprintlnproc eprintln(s: string) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
556emit_stringproc emit_string(s: string) -> void {Turns internal values into a transport or textual representation.
560print_intproc print_int(value: i64) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
564println_intproc println_int(value: i64) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
569print_floatproc print_float(value: f64) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
573println_floatproc println_float(value: f64) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
578print_boolproc print_bool(value: bool) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
586println_boolproc println_bool(value: bool) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
591printfproc printf(format: string, args: [string]) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
597fprintfproc fprintf(f: File, format: string, args: [string]) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
603sprintfproc sprintf(format: string, args: [string]) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
607snprintfproc snprintf(size: usize, format: string, args: [string]) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
617scanfproc scanf(format: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
621fscanfproc fscanf(f: File, format: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
629sscanfproc sscanf(input: string, format: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
637read_lineproc read_line() -> string {Owns byte movement or host I/O interaction.
641read_stringproc read_string() -> string {Owns byte movement or host I/O interaction.
645read_intproc read_int() -> i64 {Owns byte movement or host I/O interaction.
649read_floatproc read_float() -> f64 {Owns byte movement or host I/O interaction.
653read_boolproc read_bool() -> bool {Owns byte movement or host I/O interaction.
663read_all_stdinproc read_all_stdin() -> string {Owns byte movement or host I/O interaction.
667read_fileproc read_file(path: string) -> string {Owns byte movement or host I/O interaction.
678read_file_bytesproc read_file_bytes(path: string) -> bytes {Owns byte movement or host I/O interaction.
682read_linesproc read_lines(path: string) -> [string] {Owns byte movement or host I/O interaction.
687write_fileproc write_file(path: string, content: string) -> int {Owns byte movement or host I/O interaction.
699write_file_bytesproc write_file_bytes(path: string, content: bytes) -> int {Owns byte movement or host I/O interaction.
711append_fileproc append_file(path: string, content: string) -> int {Owns byte movement or host I/O interaction.
723copy_fileproc copy_file(src: string, dst: string) -> int {Owns byte movement or host I/O interaction.
728move_fileproc move_file(src: string, dst: string) -> int {Owns byte movement or host I/O interaction.
738removeproc remove(path: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
746renameproc rename(old_path: string, new_path: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
754file_existsproc file_exists(path: string) -> bool {Owns byte movement or host I/O interaction.
758is_fileproc is_file(path: string) -> bool {Owns byte movement or host I/O interaction.
762is_dirproc is_dir(path: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
766is_symlinkproc is_symlink(path: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
770file_sizeproc file_size(path: string) -> i64 {Owns byte movement or host I/O interaction.
774statproc stat(path: string) -> FileStat {Represents one top-level surface in the file contract and should be read as part of the module boundary.
789mkdirproc mkdir(path: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
797mkdir_allproc mkdir_all(path: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
805rmdirproc rmdir(path: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
813list_dirproc list_dir(path: string) -> [DirEntry] {Owns a concrete data shape or the operations that maintain it.
817read_dir_namesproc read_dir_names(path: string) -> [string] {Owns byte movement or host I/O interaction.
830touchproc touch(path: string) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
838tmpfileproc tmpfile() -> File {Represents one top-level surface in the file contract and should be read as part of the module boundary.
842tmpnamproc tmpnam(prefix: string) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
850basenameproc basename(path: string) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
855dirnameproc dirname(path: string) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
860extensionproc extension(path: string) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
865stemproc stem(path: string) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
870path_joinproc path_join(a: string, b: string) -> string {Owns path semantics, traversal, or normalization.
886path_join3proc path_join3(a: string, b: string, c: string) -> string {Owns path semantics, traversal, or normalization.
890path_normalizeproc path_normalize(path: string) -> string {Owns path semantics, traversal, or normalization.
894path_is_absoluteproc path_is_absolute(path: string) -> bool {Owns path semantics, traversal, or normalization.
898path_is_relativeproc path_is_relative(path: string) -> bool {Owns path semantics, traversal, or normalization.
902path_parseproc path_parse(path: string) -> PathInfo {Transforms an input representation into a structured internal value.
917buffer_newproc buffer_new(capacity: usize) -> Buffer {Owns byte movement or host I/O interaction.
926buffer_from_bytesproc buffer_from_bytes(data: bytes) -> Buffer {Owns byte movement or host I/O interaction.
935buffer_clearproc buffer_clear(buf: Buffer) -> Buffer {Owns byte movement or host I/O interaction.
943buffer_remainingproc buffer_remaining(buf: Buffer) -> usize {Owns byte movement or host I/O interaction.
951buffer_is_emptyproc buffer_is_empty(buf: Buffer) -> bool {Owns byte movement or host I/O interaction.
955reader_newproc reader_new(f: File) -> TextReader {Represents one top-level surface in the file contract and should be read as part of the module boundary.
963writer_newproc writer_new(f: File) -> TextWriter {Represents one top-level surface in the file contract and should be read as part of the module boundary.
970reader_read_lineproc reader_read_line(r: TextReader) -> string {Owns byte movement or host I/O interaction.
974writer_writeproc writer_write(w: TextWriter, s: string) -> TextWriter {Owns byte movement or host I/O interaction.
985writer_writelnproc writer_writeln(w: TextWriter, s: string) -> TextWriter {Represents one top-level surface in the file contract and should be read as part of the module boundary.
990perrorproc perror(message: string) -> void {Represents one top-level surface in the file contract and should be read as part of the module boundary.
994strerrorproc strerror(code: int) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1006setbufproc setbuf(f: File, buffer: bytes) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1014setvbufproc setvbuf(f: File, buffer: bytes, mode: i32, size: i64) -> int {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1026format_applyproc format_apply(format: string, args: [string]) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1048to_string_i64proc to_string_i64(value: i64) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1052to_string_f64proc to_string_f64(value: f64) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1056parse_i64proc parse_i64(s: string) -> i64 {Transforms an input representation into a structured internal value.
1060parse_f64proc parse_f64(s: string) -> f64 {Transforms an input representation into a structured internal value.
1064split_linesproc split_lines(s: string) -> [string] {Owns path semantics, traversal, or normalization.
1068string_containsproc string_contains(s: string, needle: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1072string_starts_withproc string_starts_with(s: string, prefix: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1076string_ends_withproc string_ends_with(s: string, suffix: string) -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1080string_sliceproc string_slice(s: string, start: int, end: int) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1084string_char_atproc string_char_at(s: string, index: int) -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1088io_readyproc io_ready() -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1092io_domainsproc io_domains() -> [string] {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1105library_metaproc library_meta() -> string {Represents one top-level surface in the file contract and should be read as part of the module boundary.
1109io_selftestproc io_selftest() -> bool {Represents one top-level surface in the file contract and should be read as part of the module boundary.

Exports

LineNameSignatureRole
3*export *Re-exports surfaces that the module wants to expose as part of its public boundary.

Integration boundaries

Within io, this file should remain focused. If a future helper changes the host boundary, scheduling boundary, or data-shape boundary, it probably belongs in a neighbor module instead of being added here by convenience.

  • Family responsibility: File, buffer, stream, stdio, and host-runtime access helpers.
  • Family architecture role: Use `io` when the program must read or write bytes, files, or streams. Keep it separate from validation, parsing, or business decisions.

Composition guidance

Choose this module when

  • Choose io.vitl when the main question is owned by this module rather than by transport, storage, orchestration, or user-interface code.
  • A manifest is loaded through `io`, parsed elsewhere, validated elsewhere, and only then emitted back through `io`.
  • A stdio helper should explain where user-facing text enters the flow.

Pause before extending it when

  • Avoid extending this file when the new helper mostly changes the boundary to host I/O, runtime coordination, or foreign integration instead of staying inside io.
  • Check nearby modules such as io/buffer.vitl, io/file.vitl, io/fileops.vitl before adding convenience wrappers here.

Relationship table

This table keeps the page closer to a real encyclopedia entry: a module is easier to understand when compared with its nearest alternatives in the same family.

NeighborProceduresData surfacesWhy compare it
io/buffer.vitl134Shares the same family boundary but carries a distinct slice of responsibility.
io/file.vitl234Shares the same family boundary but carries a distinct slice of responsibility.
io/fileops.vitl193Shares the same family boundary but carries a distinct slice of responsibility.
io/host_runtime.vitl170Shares the same family boundary but carries a distinct slice of responsibility.
io/io.vitl410Shares the same family boundary but carries a distinct slice of responsibility.
io/stdio.vitl354Shares the same family boundary but carries a distinct slice of responsibility.
io/stream.vitl134Shares the same family boundary but carries a distinct slice of responsibility.

Neighbor modules