To use this website fully, you first need to accept the use of cookies. By agreeing to the use of cookies you consent to the use of functional cookies. For more information read this page.

ZPE 1.11.4 union types

Finally, union types are accepted in ZPE 1.11.4. The March release known as OmegaZ will now include union return types:

function doubleNum(integer $x) : integer | real
  return $x * 2
end function
print(doubleNum(2))

It will also soon support union parameter and variable declarations which are expected in OmegaY also. This further expansion of ZPE's TYPO nudges TYPO to version 2.1. All of this new stuff has been added with almost no performance penalty at all. 

Posted by jamiebalfour04 in General
Comments
Powered by DASH 2.0 (beta)
Code previewClose