Re: The goto statement in PHP [message #185739 is a reply to message #185734] |
Mon, 05 May 2014 15:08 |
Mr Oldies
Messages: 241 Registered: October 2013
Karma:
|
Senior Member |
|
|
On Mon, 05 May 2014 10:27:36 -0400, Jerry Stuckle wrote:
> On 5/5/2014 9:50 AM, richard wrote:
>> In Liberty BASIC (LB) we also have branched goto labels.
>> As I was reading the goto manual on php.net I see where they make no
>> distinction between a label and a variable.
>> In LB it is simple.
>> a=0 is a distinct variable.
>> [a] is a distinct label.
>>
>> When goto [a] is encountered, it matters not what or where the variable "a"
>> is.
>>
>> I'm just suggesting that they need a means to distinguish the pair.
>>
>
> Better yet - don't use goto. I never have needed it.
Yeah I know. I've heard it a zillion times before.
"Any language that uses a 'goto' is one that is screwed up".
But hey, there are times when the evil is required.
I recall a scene from a movie.
Dozens of federal agents armed to the teeth break into a hacker's
residence.
He's busy trying to erase all of his hard work so they have no evidence.
"No you got it wrong boy. We're not here to bust you. This time. We're to
hire you!".
Purely for the drama of course.
|
|
|