IPB

Welcome Guest ( Log In | Register )

Recommended
BootDisk.com

Active Users

 
Reply to this topicStart new topic
Parameter Stack, Question to forum
psc
post Sep 6 2008, 09:15 AM
Post #1


Guru
***

Group: .script developer
Posts: 5,404
Thank(s): 83
Joined: 14-July 06
From: Korschenbroich
Member No.: 3


Germany


Like suggested by cdob, I did a small change to WinBuilder:

The #1, #2, ... of the 'Run' and 'Loop' command are stacked:

That results in:
CODE
[process]
run,%scriptFile%,Erster,1-1,1-2,1-3
Echo,#1
Echo,#2
Echo,#3
Echo,#4
Echo,#5

[erster]
run,%scriptFile%,Zweiter,2-1,2-2
Echo,#1
Echo,#2
Echo,#3
Echo,#4
Echo,#5

[zweiter]
run,%scriptFile%,Dritter,3-1,3-2,3-3,3-4
Echo,#1
Echo,#2
Echo,#3
Echo,#4
Echo,#5

[dritter]
Echo,#1
Echo,#2
Echo,#3
Echo,#4
Echo,#5

bringing:
Attached Image

Looks nice and is form with 'higher languages procedure call'

But there is one difficulty:

Several scripts use some parameters by reference rather than by value.
They depend on the returned values.

If in the future we introduce the paramter stack, these scripts will fail.

What to do?

Peter

BTW to compare the result w/o stack
Attached Image
Go to the top of the page
 
+Quote Post
ctmag
post Sep 6 2008, 09:54 AM
Post #2


Advanced Member
***

Group: .script developer
Posts: 362
Thank(s): 14
Joined: 19-May 08
Member No.: 15,320


Germany


hmmm i prefer not to be incompatible with current scripts...this will keep users from switching to the latest wb version for quite a while...
Go to the top of the page
 
+Quote Post
psc
post Sep 6 2008, 11:22 AM
Post #3


Guru
***

Group: .script developer
Posts: 5,404
Thank(s): 83
Joined: 14-July 06
From: Korschenbroich
Member No.: 3


Germany


QUOTE (ctmag @ Sep 6 2008, 11:54 AM) *
hmmm i prefer not to be incompatible with current scripts...this will keep users from switching to the latest wb version for quite a while...

Currently I can switch 'on the fly'
CODE
  const
  // wich version are we using?
  Version = '075';
  Beta = 'beta 4 r';

  // this flag defines whether Run parameters #1, ... are stacked or used in the ancient way
  useParmStack = TRue;

  // this flag defines whether source is saved automatically when leaving the source editor
  autoSave = True;

...
Go to the top of the page
 
+Quote Post
Nuno Brito
post Sep 6 2008, 11:56 AM
Post #4


Advanced Member
***

Group: .script developer
Posts: 6,137
Thank(s): 127
Joined: 13-July 06
From: Azores
Member No.: 1


Portugal


Further testing is required on this case.

Is it possible to evaluate which scripts are failing under VistaPE and LiveXP? (IMG:../forums/style_emoticons/default/huh.gif)

wb gets "smarter" but I remember that in several code portions, the parameter would be reseted to "" if it wasn't used and therefore people would repeat them over the next script run process to ensure that they were still present.

If this is the case for most scripts then the overall project should work as it is intended with both methods without worries.

(IMG:../forums/style_emoticons/default/smile.gif)
Go to the top of the page
 
+Quote Post
psc
post Sep 6 2008, 12:01 PM
Post #5


Guru
***

Group: .script developer
Posts: 5,404
Thank(s): 83
Joined: 14-July 06
From: Korschenbroich
Member No.: 3


Germany


QUOTE (Nuno Brito @ Sep 6 2008, 01:56 PM) *
Further testing is required on this case.

Is it possible to evaluate which scripts are failing under VistaPE and LiveXP? (IMG:../forums/style_emoticons/default/huh.gif)

wb gets "smarter" but I remember that in several code portions, the parameter would be reseted to "" if it wasn't used and therefore people would repeat them over the next script run process to ensure that they were still present.

If this is the case for most scripts then the overall project should work as it is intended with both methods without worries.

(IMG:../forums/style_emoticons/default/smile.gif)

So, I suggest to have stack in the beta.
If too many apps fail, the final rlease may have the old functionality.

Peter
Go to the top of the page
 
+Quote Post
« Next Oldest · Development · Next Newest »
 

Fast ReplyReply to this topicStart new topic
2 User(s) are reading this topic (2 Guests and 0 Anonymous Users)
0 Members:

 

Display Mode: Standard · Switch to: Linear+ · Switch to: Outline

Track this topic · Email this topic · Print this topic · Subscribe to this forum

RSS Lo-Fi Version Time is now: 12th October 2008 - 08:55 AM

W3C XHTML • © 2008 Boot Land • All rights reserved • W3C CSS