
-----------------------------------
Banished_Outlaw
Fri Apr 13, 2007 10:34 pm

Can Procedures Be Disabled?
-----------------------------------
Is there any command in Turing that can disable a procedure. 

I have an if condition in my program and when the if condition is true, I want all the procedures that follow it, to be disabled or not to show on the run screen.

I would really appreciate any suggestions.  :|

-----------------------------------
Tony
Sat Apr 14, 2007 12:31 am

RE:Can Procedures Be Disabled?
-----------------------------------
You could do something like

procedure foo()
if global_flag then
   return
end if
...
end foo


-----------------------------------
ericfourfour
Sat Apr 14, 2007 1:13 am

RE:Can Procedures Be Disabled?
-----------------------------------
Or, you can only call the procedure if a certain condition is true.

if condition then
    procedure_call()
end if

-----------------------------------
Superskull85
Sat Apr 14, 2007 7:10 pm

Re: Can Procedures Be Disabled?
-----------------------------------
I'd go the condition option. 

P.S. This is off topic but, what does "..." do in Turing?

-----------------------------------
Clayton
Sat Apr 14, 2007 8:10 pm

RE:Can Procedures Be Disabled?
-----------------------------------
It does nothing... have you ever tried running code with ... in Turing? It just means "put your code here"

-----------------------------------
neufelni
Sat Apr 14, 2007 8:33 pm

RE:Can Procedures Be Disabled?
-----------------------------------
I think that he may mean .. which causes the next line of output to be put on the same line rather than a new line.

-----------------------------------
Superskull85
Sat Apr 14, 2007 9:53 pm

Re: RE:Can Procedures Be Disabled?
-----------------------------------
It does nothing... have you ever tried running code with ... in Turing? It just means "put your code here"

I have and it just gives me an error. I just wanted to know because I've seen it around a lot and I wanted to know maybe I was using it wrong. I was putting it by itself, but there are other words/symbols like; and, or, of, end, exit, (,), .., : etc. that need to be accompanied by other words/symbols to work properly. I just wanted to know if this was one of them, but now I know it isn't.

-----------------------------------
Tony
Sat Apr 14, 2007 10:01 pm

RE:Can Procedures Be Disabled?
-----------------------------------
Indeed ... is usually a placeholder for more text. It often represents silence when speech is expected, such as in Final Fantasy games ;) Here it could be read as "your code goes here".
