Only valid in PHP?

you are viewing a single comment's thread
view the rest of the comments
[–] 2 points 1 year ago* (2 children)

Boolean functions have potentially infinite return states depending on error handling

  • True
  • False
  • NA
  • NULL
  • Error1 "You done messed up."
  • Error2 "You done messed up differently. But again."
  • Error3 "My tender bosom heaves in anguish"

etc

  • source
  • hideshow 2 child comments
  • [–] 6 points 1 year ago (1 child)

    Not in my functional language with no nulls :P

  • source
  • parent
  • hideshow 1 child comment
  • [–] 1 point 1 year ago*

    It still can panic/abort and deadlock/wait infinitely long on most fp languages because that's typically implied. And there isn't actually a way around that because computation almost always can fail or block indefinitely - and if you have a total language you can implement waits for billions of years, which for all practical purposes is "infinitely" long on human time scales.

  • source
  • parent