Previous: , Up: Other I/O   [Contents][Index]

5.20.13 CSV Reader

Comma-separated values (CSV) are a popular text format to interchange data. Gforth provides an reader in csv.fs.

read-csv ( addr u xt –  ) gforth-experimental “read-csv”

read CVS file addr u and execute xt for every item found. xt takes ( addr u col line -- ), i.e. the string, the current column (starting with 0), and the current line (starting with 1).