Simple and makes much more sense than Python's solution IMO:
    
    
    proc test(): int =
      return 1
    
    proc main() =
      if (var x = test(); x) == 1:
          echo x
    
    main()
    
    
    Run

Reply via email to