Sujet : Re: New VSI post on Youtube
De : clubley (at) *nospam* remove_me.eisner.decus.org-Earth.UFP (Simon Clubley)
Groupes : comp.os.vmsDate : 20. Aug 2024, 13:36:51
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <va22l3$3cdrf$4@dont-email.me>
References : 1 2 3 4 5 6 7 8 9 10
User-Agent : slrn/0.9.8.1 (VMS/Multinet)
On 2024-08-20, chrisq <
devzero@nospam.com> wrote:
>
I guess another complication is that some functions return
-1, which implies a signed variable. To fix all that would require a
complete rewrite of the library and probably most of the os and
applications as well, so it will never happen. Just have to write
unsigned equivalents, or slip functions with casts, but it's a lot
of additional work.
>
One thing I wish was available in all languages is the ability to return
multiple values from a function call so you can return both a status and
the value(s) in one assignment. Ie: "a, b, c = demo_function(param1, param2);".
In languages with dynamic associative arrays (such as PHP), I simulate
this by returning an associative array from a function call with both
status and value fields. Makes coding _so_ much cleaner and robust.
Simon.
-- Simon Clubley, clubley@remove_me.eisner.decus.org-Earth.UFPWalking destinations on a map are further away than they appear.