Re: Euphoria question routine_id

new topic     » goto parent     » topic index » view thread      » older message » newer message

In my BBCMF code, I've standardized on a function return sequence that provides a success boolean and the result. For instance:

function sample_func(sequence s)
  if length(s) > 25 then 
     return {1,s[1..25]} -- success 
  else 
     return {0,""}       -- fail 
  end if 
end function 

This is similar to how value() behaves. I did this to remove the ambiguities (that Bernie just posted about) because I use a lot of routine_id() and call_func/proc().

YMMV

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu