Typing for repl/infinite-loop type

Viewed 46

Let's say I have a function such as the following:

def echo() -> NoReturn: # correct?
    while True:
        val = input('echo> ')
        print (val)

What would be the correct type for this? Would this more along the lines of None or NoReturn or something else?

0 Answers
Related