Posted to tcl by aspect at Sat May 10 19:08:31 GMT 2008view pretty

namespace eval putschan {
    proc initialize {fd mode} {
        return {}
    }
    proc finalize {fd} {
        return {}
    }
    proc watch {fd ev} {
        return {}
    }
    proc seek {fd ofs} { return {} }
    proc configure {fd opt val} { return {} }
    proc cget {fd} { return {} }
    proc cgetall {fd} { return {} }
    proc blocking {fd mode} { return {} }
    proc write {fd data} {
        puts $data
    }
    namespace export *
    namespace ensemble create
}


set fd [chan create write cbchan]
puts $fd "Hello, World!"
close $fd