I must say that I agree with you Cetin, that a RETURN can and should go where it makes the most sense, and that includes aiding readability.
To me it is more readable/useful for a code READER to see immediately that a RETURN is done rather than to have to continue to read yet more code, possibly with added IF structures just to exclude (again) the specific RETURN condition anyway.
I will admit that, since about a year now, I have included a long comment in such lines, like the following, to help readers identify such occurrences
lparameters p1,p2,p3
with this
if !.Something(p1,p2,p3)
return .f.
endif
....
cheers
>>Hi
>>
>>if you are using with endwith should you never jump out of the middle.
>>
>>ie
>>
>>WITH
>>
>>return
>>ENDWITH
>>
>>I can see it looks like a bad thing to do but whats the actual impact.
>>
>>Thanks
>>
>>Nick Mason
>
>I don't like to strictly follow the general practices and on this subject I certainly do not follow :)
>I think it's up to the programmer to have a return in the middle of a proc/loop/check etc. If I can control it why wouldn't I do that. ie:
>
>
>* a method
>lparameters p1,p2,p3
>with this
> if !.Something(p1,p2,p3)
> return .f.
> endif
>....
>
>Only impact IMHO is if you can't control your coding, IOW readability maybe.
>Cetin