Walter Meester
HoogkarspelPays-Bas
George,
>I think the above is less readable than
>IF NOT userHasNoDeletePermission()
> * Stuff to delete
>ENDIF
>RETURN llresult
>and that it can make debugging harder depending on the circumstances.
Wel it depends... If there is a lot of coding between the IF and ENDIF you have to scroll your code to make sure there is nothing after the endif when reading and analyzing the code.
Another drawback is that it requires another indent of tabs (or spaces) to format your code, which *can* have a negative impact on readability.
>I'd be more likely to name the function UserHasDeletePermission()
You're right, I was only making an example. In practice I don't have procs named like that.
Walter,
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement