A follow-up: flushing stdout works in console, but not in Xcode. Neither setbuf(stdout, nil) nor fflush(stdout) helps, so it appears this is an Xcode issue.
import Darwin setbuf(stdout, nil) while true { print("A question.") print("Your answer: ", terminator: "") // not printed //fflush(stdout) sleep(1) print("") } Regards, Andrey > On 8 Feb 2017, at 20:04, Andrey Fidrya <a...@zabiyaka.com> wrote: > > Hi All, > > In Xcode 8.3 beta print() stopped outputting unterminated lines: > https://bugs.swift.org/browse/SR-3827 <https://bugs.swift.org/browse/SR-3827> > > I've retested with recently released beta 2 and the issue is still present. > Could anyone from dev team take a look at this issue please? > I'm worried that it will make into release because it makes working > with interactive console apps impossible. > > Regards, > Andrey >
_______________________________________________ swift-users mailing list swift-users@swift.org https://lists.swift.org/mailman/listinfo/swift-users