home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   sci.electronics.design      Electronic circuit design      143,326 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 142,924 of 143,326   
   Martin Brown to Don Y   
   Re: Call by reference protection   
   20 Feb 26 10:36:13   
   
   From: '''newspam'''@nonad.co.uk   
      
   On 19/02/2026 22:04, Don Y wrote:   
   > [Obdisclaimer:  cc'ing s.e.d only because some of you are no longer   
   > subscribed to the list and will likely not see this, otherwise.   
   > And, its a substantial change in the API so worth noting.]   
   >   
   > Using similar mechanisms to those that I use in call-by-value RMIs,   
   > I can protect against races for call-by-reference -- throwing an   
   > exception or just spinning on any violations on the calling side.   
   >   
   > Or, I can just let people rely on their own discipline to   
   > ensure they don't introduce latent bugs via this mechanism   
   > (resorting to call by value universally seems a bad idea   
   > for legacy coders).  As these types of races have typically   
   > been hard to test for, I suspect it is worth the effort.   
   >   
   > Any pointers to languages or IDLs that include such qualifying   
   > adjectives?   
      
   Languages that allow call by reference to be qualified with a const or   
   readonly directive so that the routine reading the original object (no   
   copy made) is not allowed to alter the it in any way.   
      
   Detectable as a compile time fault if you do. Relying on all coders to   
   be disciplined is likely to be ahem... disappointing.   
      
   I can't be the only one to have seen shops where the journeymen are so   
   unskilled that getting C code to compile by the random application of   
   casts is the norm. Not written in C but the UK scandalous Horizon PO   
   accounting system was written by people of that calibre (thickness).   
      
   They compounded the problem by having expert witnesses perjure   
   themselves to convict entirely innocent postmasters of fraud because the   
   computer was "infallible". The resulting mess is still ongoing.   
      
   --   
   Martin Brown   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca