mirror of
https://github.com/taigrr/bubbletea.git
synced 2026-04-02 11:09:17 -07:00
This commit implements cancelable reads, which allows Bubble Tea programs to run in succession in a single application. It also makes sure all goroutines terminate before `Program.Start()` returns. Closes #24.
15 lines
422 B
Go
15 lines
422 B
Go
//go:build !darwin && !windows && !linux && !solaris && !freebsd && !netbsd && !openbsd
|
|
// +build !darwin,!windows,!linux,!solaris,!freebsd,!netbsd,!openbsd
|
|
|
|
package tea
|
|
|
|
import (
|
|
"io"
|
|
)
|
|
|
|
// newCancelReader returns a fallbackCancelReader that satisfies the
|
|
// cancelReader but does not actually support cancelation.
|
|
func newCancelReader(reader io.Reader) (cancelReader, error) {
|
|
return newFallbackCancelReader(reader)
|
|
}
|