✨ ARCANUM RUNE DIFFICULTY: Adept Creational

The Solitary Buffer (Singleton)

Ensuring only one instance of a sacred text exists across the entire stream processing.

✧ GANG OF FOUR LINEAGE & ARCANUM ✧
GOF DESIGN PATTERN: Singleton
ARCANUM SCHOOL: Transmutation // Streamweaving
SCRIBE / ARCHON: Joshua Edward McLaughlin Cox
CANONICAL REGISTRATION:
// CODEX INCANTATION //
# Singleton: Initialize only if hold space is empty
1 {
  # On first line, populate the singleton in hold space
  x
  s/^$/[SINGLETON INSTANCE]/
  x
}
/GET_SINGLETON/ {
  x
  p
  x
  d
}
Runic Tags: #sed #creational #singleton