Compiler bug?: Infinite loop when compiling pegging CPU

2021-05-20 Thread abc
Hi @pietroppeter \- I agree that it's quite a silly example. But shouldn't the compiler catch this or preferably crash? It seems wrong that it just pegs two om my CPU cores until i manually kill the processes. Also this example compiles and runs without any problems: import sequti

Compiler bug?: Infinite loop when compiling pegging CPU

2021-05-20 Thread abc
Hi @shirleyquirk Thanks for clarifying. This makes sense to me. I stumbled upon this bug while doing some Project Euler exercises, and fixed the problem by using let instead of const. I posted in on here as I was curious. :)

Compiler bug?: Infinite loop when compiling pegging CPU

2021-05-19 Thread abc
Hi Nim people, I was using Nim for some Project Euler exercises. When I tried to compile with `nim c -r -d:debug test.nim`, it got stuck after printing Hint: used config file '/etc/nim/nim.cfg' [Conf] Hint: used config file '/etc/nim/config.nims' [Conf] ..