Add example with mixed types for ^

git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@259056 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Etienne Kneuss 2008-05-04 20:54:38 +00:00
parent e244d1e51c
commit de8f418b79

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.124 $ -->
<!-- $Revision: 1.125 $ -->
<chapter xml:id="language.operators" xmlns="http://docbook.org/ns/docbook">
<title>Operators</title>
<simpara>
@ -392,6 +392,12 @@ echo "12" ^ "9"; // Outputs the Backspace character (ascii 8)
echo "hallo" ^ "hello"; // Outputs the ascii values #0 #4 #0 #0 #0
// 'a' ^ 'e' = #4
echo 2 ^ "3"; // Outputs 1
// 2 ^ ((int)"3") == 1
echo "2" ^ 3; // Outputs 1
// ((int)"2") ^ 3 == 1
?>
]]>
</programlisting>