INim icon indicating copy to clipboard operation
INim copied to clipboard

os.sleep is not working properly

Open hamidb80 opened this issue 3 years ago • 1 comments

info:

  • nim compiler version: 1.4.8
  • inim version : 0.6.1
  • os: windows 10

the code:

import os

nim> proc uuu=   
     echo "start"
     sleep 1000
     echo "end"

nim> uuu()

result: it prints "end" immediately after printing "start"

expected behavior: it should sleep for 1s and then print "end"

hamidb80 avatar Jun 04 '21 06:06 hamidb80

Confirmed.

I wonder if it is something to do with the whole line being executed and only then the output is printed?

0atman avatar Mar 30 '22 09:03 0atman