You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is well known that using the initialiser syntax on local variables makes them "saved" and therefore global scope, i.e. persistent between calls. This is very rarely useful behaviour in modern code.
It was thought that pointers were an exception to this rule but it has become clear they are not. As such the missing pointer initialisation rule is not useful.
It should be replaced by two new rules. One which ensures there are no declaration initialisations. This will prevent any of those implicit globals.
The second is a check that the first thing in the code of any procedure is nullification of any local pointers. This may be spread across one or more nullify statements.
The text was updated successfully, but these errors were encountered:
It is well known that using the initialiser syntax on local variables makes them "saved" and therefore global scope, i.e. persistent between calls. This is very rarely useful behaviour in modern code.
It was thought that pointers were an exception to this rule but it has become clear they are not. As such the missing pointer initialisation rule is not useful.
It should be replaced by two new rules. One which ensures there are no declaration initialisations. This will prevent any of those implicit globals.
The second is a check that the first thing in the code of any procedure is nullification of any local pointers. This may be spread across one or more
nullify
statements.The text was updated successfully, but these errors were encountered: