Inappropriate loops behaviour <for(), foreach(), break, continue>, segmentation fault while producing stacktrace #62
Labels
Sans labels
aerscript
bug
duplicate
enhancement
help wanted
idea
question
won't fix
Sans jalon
Sans assignation
1 participants
Notifications
Échéance
Aucune échéance n'a été définie.
Dépendances
Aucune dépendance définie.
Référence : aerscript/Aer#62
Chargement…
Référencer dans un nouveau ticket
Sans contenu.
Supprimer la branche "%!s(<nil>)"
La suppression d’une branche est permanente. Bien qu’une branche supprimée puisse temporairement subsister, elle NE PEUT PAS être facilement restaurée. Continuer ?
AerScript Information
ab36234ff3
Your problem description
I have written another test - sudoku solver. It causes AerScript interpreter to fail. Sometimes it simply results in no solution, sometimes throws segmentation fault. When investigating issue, I realized this is connected with LOOP frames. After modifying code, to not declare variables repeatedly inside loops and removing OP_LOOP_START and OP_LOOP_START calls from PH7_CompileFor(), PH7_CompileBreak() and PH7_CompileContinue(), attached script has begun to work properly. Additionally, during investigation I have found another problem with for() loop statement:
Expected results
Current results
Attached affected script.
Revisions
c730082fa0
and709b5971c6
fixes the segmentation fault problem. There is still a need to investigate and resolve problem of variables scopes.Sudoku solver test added in
3eb82e632b
.