PathrockNetwork Gno Explorer
HomeBlocksTransactionsTokensRealmsPackagesValidatorsAnalytics

PathrockNetwork Gno Explorer — an independent explorer for Gno.land Mainnet (gnoland-1), operated by PathrockNetwork. Not an official Gno.land service.

gnowebarchive RPC

gno.land/r/moul/x/daily/ringbufferdemo/v0

Realm
Open in gnoweb ↗

Overview

Kind
Realm (renderable)
Name
v0
Namespace
moul / x / daily / ringbufferdemo
Files
3 (README)(gnomod.toml)
Exported functions
1
Module
gno.land/r/moul/x/daily/ringbufferdemo/v0
gno
0.9

Files (3)

  • README.mdmarkdown
  • gnomod.tomltoml
  • ringbufferdemo.gnogno

Select a file to view its exact on-chain source. Sorted README → gnomod → sources → tests.

Functions

  • Render(path string) string

Signatures reconstructed verbatim from vm/qfuncs — interface params keep their inline definitions.

Rendered

RenderedRawgnoweb ↗
# Ring Buffer

A fixed-capacity FIFO that overwrites its oldest entry, demoing the [`p/moul/x/daily/ringbuffer`](/p/moul/x/daily/ringbuffer/v0) library.

Capacity **4**, pushing 6 entries:

| push | evicted | contents (oldest → newest) |
|---|---|---|
| `alpha` | — | `alpha` |
| `bravo` | — | `alpha bravo` |
| `charlie` | — | `alpha bravo charlie` |
| `delta` | — | `alpha bravo charlie delta` |
| `echo` | `alpha` | `bravo charlie delta echo` |
| `foxtrot` | `bravo` | `charlie delta echo foxtrot` |

> The buffer never grows: once full, each push costs the oldest entry. On chain that bound is the point — an unbounded queue is an unbounded storage bill.

vm/qrender output, sanitized (docs/render-security.md) and displayed in an empty-sandbox iframe — scripts, forms and popups cannot run. Links stay inert in-preview; right-click to open.