summary refs log blame commit diff stats
path: root/tests/js/t12223.nim
blob: c0e75fb44f25c3e1875594890aa07b69f5835779 (plain) (tree)



















                                           
discard """
  action: "run"
  output: '''
caught
index out of bounds, the container is empty
'''
"""

proc fun() =
  var z: seq[string]
  discard z[4]

proc main()=
  try:
    fun()
  except Exception as e:
    echo "caught"
    echo getCurrentExceptionMsg()

main()