tcl::chan::std(n)

πŸ“¦
version 2.0 Β· 2 versions
, in fedora 43, fedora 44, nixos 26.05, nixpkgs unstable

πŸ’– tcl::chan::std β€” the standard-io glow-up πŸ’–

okay bestie so this is a page from the Reflected/virtual channel support manual (that's the manual name, love that for it), and it's all about tcl::chan::std β€” Standard I/O, unification of stdin and stdout. yes. exactly what it sounds like. stdin and stdout, holding hands, one channel. iconic. 🫢


✨ SYNOPSIS ✨

package require Tcl 8.5 9

package require TclOO

package require tcl::chan::core ?1.1?

package require tcl::chan::std ?1.1?

::tcl::chan::std

like, that's the whole vibe. no cap. 🌸


🌈 DESCRIPTION 🌈

so the tcl::chan::std package gives you a command that creates a standard channel which unifies stdin and stdout into a single read- and writable channel. one channel. both jobs. she's doing it all, main character energy fr fr πŸ‘‘

and the result is not seek-able β€” same as the original standard channels. so don't come for her about seeking, she simply does not do that. πŸ’…

also, the internal TclOO class that implements the channel handler? it's a sub-class of the tcl::chan::core framework. cute family tree, honestly. 🧚


πŸŽ€ API πŸŽ€

  • ::tcl::chan::std β€” this command creates the std channel and hands you back its handle. and here's the tea: the channel is created only once, on the first call. every call after that? just returns that same handle. she's loyal. no duplicates, no drama. πŸ’–

😭 BUGS, IDEAS, FEEDBACK 😭

okay so real talk β€” this document, and the package it describes, will undoubtedly contain bugs and other problems. yes, the manpage itself is admitting it. we love honesty. πŸ™ˆ

please report those in the category virtchannel of the Tcllib Trackers at http://core.tcl.tk/tcllib/reportlist.

and please also report any ideas for enhancements you may have for either the package and/or the documentation. we want them. bring them. ✨

when you're proposing code changes, please provide unified diffs, i.e the output of diff -u. that's the requirement, bestie, no shortcuts.

also note, further: attachments are strongly preferred over inlined patches. to make an attachment, go to the Edit form of the ticket immediately after its creation, and then use the left-most button in the secondary navigation bar. that's the whole process, you got this. πŸ¦‹


πŸ‘‘ KEYWORDS πŸ‘‘

  • reflected channel
  • standard io
  • stdin
  • stdout
  • tip 219
  • virtual channel

πŸ“ CATEGORY πŸ“

Channels


Copyright (c) 2011 Andreas Kupries <andreas_kupries@users.sourceforge.net>


and that's the whole page, bestie β€” tcllib, version 1.1, from the tcl::chan::std(n) page itself. go unify some standard io, you absolute legend β­πŸ’…πŸ”₯

πŸ“¦ where this page comes from