Re: Nimscript: setLen segfaults?

2017-09-25 Thread Udiknedormin
@cdome It wasn't a nil in this case.

Re: Nimscript: setLen segfaults?

2017-09-23 Thread cdome
seq can be nil, you need to check for that sometimes. KeepitIf will segfault if you will pass nil.

Re: Nimscript: setLen segfaults?

2017-09-23 Thread Udiknedormin
task tests, "run tests": --hints: off --linedir: on --stacktrace: on --linetrace: on --debuginfo --path: "." --run var dir_list = listDirs("tests") dir_list.keepItIf(it != "tests/nimcache") # segfaults task tests,

Re: Nimscript: setLen segfaults?

2017-09-22 Thread Tiberium
Udiknedormin: can you post a code example? And also create an issue on github

Nimscript: setLen segfaults?

2017-09-22 Thread Udiknedormin
When I used keepItIf in a nimble scirpt, it segfaulted. After copy-pasting the templates body and trying to play with it a little bit it turned out setLen was the one to blame. If I replace moving the elements to adding them to another seq and then assign it to the original one, everything