Opened 17 years ago
Closed 17 years ago
#548 closed defect (fixed)
While command doesn't return a value
Reported by: | ftakao | Owned by: | Víctor de Buen Remiro |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | Kernel | Version: | 1.1.5 |
Severity: | normal | Keywords: | |
Cc: |
Description
According to documentation, the while command should return a value and assign this value to a variable:
Anything While(Real condition, Anything whatToDo)
However, the code below generates an error and doesn't create the returnValue set:
Real continue = 0;
Set returnValue = While(Not(continue),
{
Real Sleep(1);
Text doTest = TclTkMessageBox(SetOfSet(
TclArgSt("-title", "Dialogo TclYesNoQuestion"),
TclArgSt("-message", "¿Deseja sair do while?"),
TclArgSt("-type", "yesno"),
TclArgSt("-icon", "question")
));
Real continue := If(doTest=="yes",1,0);
Set 1,2?
});
Change History (4)
comment:1 Changed 17 years ago by
Severity: | blocker → normal |
---|
comment:2 Changed 17 years ago by
Owner: | changed from danirus to Víctor de Buen Remiro |
---|
comment:3 Changed 17 years ago by
Status: | new → assigned |
---|
Correct syntax could be something as
Real continue = 0;
While(Not(continue),
{
Real Sleep(1);
Text doTest = TclTkMessageBox(SetOfSet(
TclArgSt("-title", "Dialogo TclYesNoQuestion"),
TclArgSt("-message", "�Deseja sair do while?"),
TclArgSt("-type", "yesno"),
TclArgSt("-icon", "question")
));
Real continue := If(doTest=="yes",1,0)
});
comment:4 Changed 17 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
This problem has been solved in CVS for HEAD 1.1.7 and 1.1.6 branches
2nd argument of While function must be evaluated with GraAnything and description explain that is a non declarative tag.
Thanks to report it
Well, it seems that the description is obsolete
I will change it
Thank you for report it