[{"data":1,"prerenderedAt":4},["ShallowReactive",2],{"docs:\u002Fdocs\u002Ftooling\u002Flibraries":3},"\u003Cp>A library written in Phaenon can be published so that \u003Ccode>composer require\u003C\u002Fcode> brings plain PHP: any\nproject installs it, with or without Phaenon, and nothing in it calls a Phaenon package. The\nlibrary commits its compiled outputs beside its \u003Ccode>.phn\u003C\u002Fcode> and names them in \u003Ccode>phaenon.json\u003C\u002Fcode>; its CI\nchecks that they are what its sources compile to.\u003C\u002Fp>\n\u003Ch2 id=\"two-ways-to-publish\">Two ways to publish\u003Ca class=\"docs-anchor\" href=\"#two-ways-to-publish\" aria-hidden=\"true\" tabindex=\"-1\">#\u003C\u002Fa>\u003C\u002Fh2>\n\u003Cdiv class=\"docs-table\">\u003Ctable>\u003Cthead>\u003Ctr>\u003Cth>\u003C\u002Fth>\u003Cth>Outputs committed (\u003Ccode>&quot;committed&quot;\u003C\u002Fcode>)\u003C\u002Fth>\u003Cth>Sources only\u003C\u002Fth>\u003C\u002Ftr>\u003C\u002Fthead>\u003Ctbody>\u003Ctr>\u003Ctd>The repository holds\u003C\u002Ftd>\u003Ctd>\u003Ccode>src\u002F*.phn\u003C\u002Fcode> and \u003Ccode>.src\u002F*.php\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>\u003Ccode>src\u002F*.phn\u003C\u002Fcode>\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>A project without Phaenon gets\u003C\u002Ftd>\u003Ctd>The compiled PHP, ready to load\u003C\u002Ftd>\u003Ctd>Nothing it can load without the plugin\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>A project written in Phaenon gets\u003C\u002Ftd>\u003Ctd>The compiled PHP, and the checker reads the \u003Ccode>.phn\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>Its plugin builds the library at every autoload dump\u003C\u002Ftd>\u003C\u002Ftr>\u003Ctr>\u003Ctd>\u003Ccode>phaenon\u002Fphn\u003C\u002Fcode> in the library&#39;s \u003Ccode>composer.json\u003C\u002Fcode>\u003C\u002Ftd>\u003Ctd>\u003Ccode>require-dev\u003C\u002Fcode>, one exact release\u003C\u002Ftd>\u003Ctd>\u003Ccode>require\u003C\u002Fcode>, a range\u003C\u002Ftd>\u003C\u002Ftr>\u003C\u002Ftbody>\u003C\u002Ftable>\u003C\u002Fdiv>\n\u003Cp>Shipping sources only suits a library whose consumers are Phaenon projects already. A library for\nPHP projects at large commits its outputs; the rest of this page is about that way.\u003C\u002Fp>\n\u003Ch2 id=\"the-repository\">The repository\u003Ca class=\"docs-anchor\" href=\"#the-repository\" aria-hidden=\"true\" tabindex=\"-1\">#\u003C\u002Fa>\u003C\u002Fh2>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>acme\u002Fmoney\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── src\u002FMoney.phn\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── src\u002FCurrencyMismatch.phn\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── .src\u002FMoney.php             # compiled, committed\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── .src\u002FCurrencyMismatch.php\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── tests\u002FMoneyTest.phn\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── phaenon.json\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── composer.json\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>├── .gitattributes\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>└── .gitignore\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cdiv class=\"docs-example\">\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cfigcaption class=\"docs-code-head\">\u003Cspan class=\"docs-code-file\">src\u002FMoney.phn\u003C\u002Fspan>\u003Cspan class=\"docs-code-label\">you write\u003C\u002Fspan>\u003C\u002Ffigcaption>\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">namespace\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Acme\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">final\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> readonly\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> class\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Money\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">{\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">    __construct\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> int\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $cents\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> string\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {}\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">    \u002F** The total of the amounts, null for none. *\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">    static\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> sum\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">list\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">&#x3C;\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">>\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $amounts\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">):\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\"> ?\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> throws\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> CurrencyMismatch\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">        $total \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">=\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> null\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        foreach\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> (\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$amounts \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">as\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $amount\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">            $total \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">=\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $total \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">===\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> null\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> ?\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $amount \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $total\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">plus\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$amount\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        return\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $total\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">    plus\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">):\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> throws\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> CurrencyMismatch\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        if\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> (\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">!==\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">            throw\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> new\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> CurrencyMismatch\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        return\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> new\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">cents \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">+\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">cents\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">    \u002F** The amount as stored: eight bytes, big-endian. *\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">    pack\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">():\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> bytes\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> =>\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> (\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">bytes\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> pack\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\">'J'\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">cents\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">}\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cfigcaption class=\"docs-code-head\">\u003Cspan class=\"docs-code-file\">.src\u002FMoney.php\u003C\u002Fspan>\u003Cspan class=\"docs-code-label\">phn build writes\u003C\u002Fspan>\u003C\u002Ffigcaption>\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">&#x3C;\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">?\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\">php\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">\u002F* @generated by phaenon from Money.phn *\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">declare\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\">strict_types\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">=\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\">1\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">namespace\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Acme\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">final\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> readonly\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> class\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Money\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">{\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">    public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> function\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> __construct\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> int\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $cents\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> string\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {}\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">    \u002F**\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">     * The total of the amounts, null for none.\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">     * \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#5C6170;--phn-light-font-style:italic;--phn-dark:#8A90A0;--phn-dark-font-style:italic\">@param\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-light-font-style:italic;--phn-dark:#6FC3DF;--phn-dark-font-style:italic\"> list\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">&#x3C;\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-light-font-style:italic;--phn-dark:#6FC3DF;--phn-dark-font-style:italic\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">> $amounts\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">     * \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#5C6170;--phn-light-font-style:italic;--phn-dark:#8A90A0;--phn-dark-font-style:italic\">@throws\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-light-font-style:italic;--phn-dark:#6FC3DF;--phn-dark-font-style:italic\"> CurrencyMismatch\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">     *\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">    public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> static\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> function\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> sum\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">array\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $amounts\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">):\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\"> ?\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">        $total \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">=\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> null\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        foreach\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> (\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$amounts \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">as\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $amount\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">            $total \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">=\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $total \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">===\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> null\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> ?\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $amount \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $total\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">plus\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$amount\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        return\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $total\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">    \u002F**\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">     * \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#5C6170;--phn-light-font-style:italic;--phn-dark:#8A90A0;--phn-dark-font-style:italic\">@throws\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-light-font-style:italic;--phn-dark:#6FC3DF;--phn-dark-font-style:italic\"> CurrencyMismatch\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">     *\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">    public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> function\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> plus\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">):\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Money\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        if\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> (\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\">!==\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">            throw\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> new\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> CurrencyMismatch\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        return\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> new\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">cents \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">+\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $other\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">cents\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">currency\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7C;--phn-light-font-style:italic;--phn-dark:#7D8393;--phn-dark-font-style:italic\">    \u002F** The amount as stored: eight bytes, big-endian. *\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">    public\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> function\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> pack\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">():\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> string\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">        return\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> pack\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\">'J'\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-light-font-style:italic;--phn-dark:#E2E3E7;--phn-dark-font-style:italic\">this\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">cents\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">}\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003C\u002Fdiv>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cfigcaption class=\"docs-code-head\">\u003Cspan class=\"docs-code-file\">src\u002FCurrencyMismatch.phn\u003C\u002Fspan>\u003C\u002Ffigcaption>\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">namespace\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> Acme\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">final\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> class\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> CurrencyMismatch\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\"> extends\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> \\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">DomainException\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">{\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">    __construct\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">string\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $left\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> string\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $right\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">        parent\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">::\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">__construct\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$left\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> and \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$right\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> do not add up\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">);\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">}\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>\u003Ccode>phaenon.json\u003C\u002Fcode> lists the roots whose outputs the repository tracks. The tests are not among them:\nconsumers load the library, not its tests.\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">{\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">roots\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">src\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \".src\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">tests\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \".tests\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">},\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">committed\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> [\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\">\"src\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">]}\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>\u003Ccode>composer.json\u003C\u002Fcode>:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">{\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">name\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"acme\u002Fmoney\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">description\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"Amounts of money, written in Phaenon and published as PHP\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">type\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"library\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">license\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"MIT\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">require\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">php\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"^8.5\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    },\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">require-dev\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">phaenon\u002Fphn\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"0.7.2\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">,\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">phpunit\u002Fphpunit\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"^12.5\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    },\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">conflict\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">phaenon\u002Fphn\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"&#x3C;0.5.0\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    },\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">autoload\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">psr-4\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">            \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Acme\\\\Money\\\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \".src\u002F\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    },\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">autoload-dev\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">psr-4\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">            \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Acme\\\\Money\\\\Tests\\\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \".tests\u002F\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    },\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">config\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">allow-plugins\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> {\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">            \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">phaenon\u002Fphn\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">:\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> true\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">        }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">    }\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">}\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cul>\n\u003Cli>\u003Cstrong>The compiler is a development requirement, at one exact release.\u003C\u002Fstrong> The outputs are made before\npublishing, so a consumer needs no compiler, and Composer installs no development requirement of\na dependency: no plugin, no binary, no \u003Ccode>allow-plugins\u003C\u002Fcode> question. The release is exact because\ntwo releases may write different bytes for the same source, and the committed bytes come from\none compiler.\u003C\u002Fli>\n\u003Cli>\u003Cstrong>The \u003Ccode>conflict\u003C\u002Fcode> keeps out the compilers that cannot read the sources.\u003C\u002Fstrong> It applies only where\n\u003Ccode>phaenon\u002Fphn\u003C\u002Fcode> is installed beside the library, in a project written in Phaenon, whose checker\nreads the library&#39;s \u003Ccode>.phn\u003C\u002Fcode>. Its floor is never below 0.5.0, the first release that knows\n\u003Ccode>committed\u003C\u002Fcode>, and \u003Ccode>phn build\u003C\u002Fcode> checks it (\u003Ca href=\"#the-conflict-the-build-checks\">below\u003C\u002Fa>).\u003C\u002Fli>\n\u003Cli>\u003Cstrong>No \u003Ccode>composer.lock\u003C\u002Fcode>\u003C\u002Fstrong> is committed, as in any library.\u003C\u002Fli>\n\u003Cli>\u003Cstrong>Upgrading the compiler\u003C\u002Fstrong> is one pull request: the new release in \u003Ccode>require-dev\u003C\u002Fcode>, and the\n\u003Ccode>.src\u002F\u003C\u002Fcode> it writes. The install that brings the release builds the project, so the two arrive\ntogether.\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Cp>\u003Ccode>.gitignore\u003C\u002Fcode> tracks \u003Ccode>.src\u002F\u003C\u002Fcode>, unlike an application&#39;s:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>\u002Fvendor\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>\u002F.tests\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>.phn-build\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>\u002Fcomposer.lock\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>\u003Ccode>.phn-build\u003C\u002Fcode> is the stamp a build of an installed package leaves; listing it keeps one from being\ncommitted by accident. \u003Ccode>.gitattributes\u003C\u002Fcode> marks the outputs as generated, so a pull request shows\nthem collapsed and the review is of the \u003Ccode>.phn\u003C\u002Fcode>, and keeps the tests out of the archive Packagist\nserves:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>\u002F.src\u002F** linguist-generated\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>\u002Ftests export-ignore\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>\u002F.gitignore export-ignore\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>\u002F.gitattributes export-ignore\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>The archive of a release then holds what a consumer needs: the outputs that run, the \u003Ccode>.phn\u003C\u002Fcode> their\nline maps name, and \u003Ccode>phaenon.json\u003C\u002Fcode>, through which a Phaenon consumer finds the sources:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">git\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> archive\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> v1.0.0\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\"> |\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> tar\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> -t\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>.src\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>.src\u002FCurrencyMismatch.php\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>.src\u002FMoney.php\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>composer.json\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>phaenon.json\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>src\u002F\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>src\u002FCurrencyMismatch.phn\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>src\u002FMoney.phn\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>Keep \u003Ccode>.src\u002F\u003C\u002Fcode> out of any \u003Ccode>\u002F.* export-ignore\u003C\u002Fcode> line: such a habit of PHP libraries would drop the\noutputs from every release, and nothing run on a checkout would notice.\u003C\u002Fp>\n\u003Ch2 id=\"the-gate\">The gate\u003Ca class=\"docs-anchor\" href=\"#the-gate\" aria-hidden=\"true\" tabindex=\"-1\">#\u003C\u002Fa>\u003C\u002Fh2>\n\u003Cp>The CI job that installs the dependencies builds, and then asks git whether the committed outputs\nchanged:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">composer\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> install\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --no-interaction\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --no-progress\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">vendor\u002Fbin\u002Fphn\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> build\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">git\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> diff\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --exit-code\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> .src\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">test\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> -z\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">$(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">git\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> status \u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\">--porcelain\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> .src\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">)\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\">\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">git\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> archive\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> HEAD\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#474C5A;--phn-dark:#B1B6C4\"> |\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> tar\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> -t\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cul>\n\u003Cli>\u003Ccode>phn build\u003C\u002Fcode> takes no paths and no \u003Ccode>--emit-on-error\u003C\u002Fcode>: it fails on a file with errors, and it\nmirrors the root, removing an output whose source is gone.\u003C\u002Fli>\n\u003Cli>The two git commands come after every step that builds (\u003Ccode>phn fmt --check\u003C\u002Fcode> and \u003Ccode>phn fix --check\u003C\u002Fcode>\nrebuild the outputs too). A stale output shows as modified, a missing one as untracked, an\norphan as deleted.\u003C\u002Fli>\n\u003Cli>The listing is there to read: it must show \u003Ccode>phaenon.json\u003C\u002Fcode>, \u003Ccode>src\u002F\u003C\u002Fcode> and \u003Ccode>.src\u002F\u003C\u002Fcode>, and no \u003Ccode>tests\u002F\u003C\u002Fcode>.\u003C\u002Fli>\n\u003C\u002Ful>\n\u003Cp>A source edited without a build fails it; with \u003Ccode>--stat\u003C\u002Fcode>, the diff names the output that moved:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">git\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> diff\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --exit-code\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --stat\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> --\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> .src\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan> .src\u002FCurrencyMismatch.php | 2 +-\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan> 1 file changed, 1 insertion(+), 1 deletion(-)\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>Make it a required check, merge branches up to date with the main branch, and tag releases only\non commits that passed it: one file&#39;s output can depend on another file&#39;s declarations, so two\npull requests that pass apart can leave the main branch stale together.\u003C\u002Fp>\n\u003Cp>Locally, \u003Ccode>phn build --check\u003C\u002Fcode> asks the same question and writes nothing:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>.src\u002FCurrencyMismatch.php: stale or missing\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>1 outputs are stale, 0 copies are stale, 0 outputs have no source; run `phn build`\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>The outputs also depend on the declarations of the library&#39;s dependencies, which the compiler\nreads for imports and generics, so a dependency&#39;s release can turn the gate red with no commit in\nthe library. Rebuild and commit.\u003C\u002Fp>\n\u003Ch2 id=\"the-conflict-the-build-checks\">The conflict the build checks\u003Ca class=\"docs-anchor\" href=\"#the-conflict-the-build-checks\" aria-hidden=\"true\" tabindex=\"-1\">#\u003C\u002Fa>\u003C\u002Fh2>\n\u003Cp>In a project that commits a root, \u003Ccode>phn build\u003C\u002Fcode> (without paths) and \u003Ccode>phn build --check\u003C\u002Fcode> read the\n\u003Ccode>conflict\u003C\u002Fcode> on \u003Ccode>phaenon\u002Fphn\u003C\u002Fcode> in \u003Ccode>composer.json\u003C\u002Fcode>, and fail while it lets in a release that cannot\nread the project file:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>composer.json: \"conflict\": {\"phaenon\u002Fphn\": \"&#x3C;0.4\"} does not keep this package from being installed beside phaenon\u002Fphn 0.4.1 or 0.4.0, which cannot read its phaenon.json: the key \"committed\" is known from 0.5.0 on; write \"phaenon\u002Fphn\": \"&#x3C;0.5.0\" under \"conflict\"\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>The outputs are written all the same, and the plugin&#39;s build at the dump fails the same way, so a\n\u003Ccode>composer install\u003C\u002Fcode> in the library&#39;s checkout reports it. \u003Ccode>&lt;0.5.0\u003C\u002Fcode>, \u003Ccode>&lt;0.5\u003C\u002Fcode> and \u003Ccode>&lt;=0.4.99\u003C\u002Fcode> keep out\nthe same releases and pass alike; a constraint \u003Ccode>phn\u003C\u002Fcode> cannot read fails as one that &quot;cannot be\njudged&quot;. \u003Ccode>phn check\u003C\u002Fcode>, \u003Ccode>phn watch\u003C\u002Fcode> and the editors do not ask.\u003C\u002Fp>\n\u003Ch2 id=\"where-the-library-is-installed\">Where the library is installed\u003Ca class=\"docs-anchor\" href=\"#where-the-library-is-installed\" aria-hidden=\"true\" tabindex=\"-1\">#\u003C\u002Fa>\u003C\u002Fh2>\n\u003Cp>A project without Phaenon requires the library and gets PHP; \u003Ccode>phaenon\u002Fphn\u003C\u002Fcode> is not installed and\nnothing is compiled:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">composer\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> require\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> \"acme\u002Fmoney:^1.0\"\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">php\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#B4431A;--phn-dark:#F29D6B\"> -r\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#2A7A4B;--phn-dark:#8FD3A3\"> 'require \"vendor\u002Fautoload.php\"; var_dump(Acme\\Money\\Money::sum([new Acme\\Money\\Money(100, \"EUR\"), new Acme\\Money\\Money(250, \"EUR\")])->cents);'\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>…\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>  - Locking acme\u002Fmoney (v1.0.0)\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>Writing lock file\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>Installing dependencies from lock file (including require-dev)\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>Package operations: 1 install, 0 updates, 0 removals\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>  - Installing acme\u002Fmoney (v1.0.0): Cloning 645a559370\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>Generating autoload files\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>…\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>int(350)\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>In a project written in Phaenon, the plugin leaves the committed root as installed and writes\nnothing into it. Its checker reads the library&#39;s \u003Ccode>.phn\u003C\u002Fcode>, so\nwhat a docblock cannot carry reaches the consumer: \u003Ccode>pack()\u003C\u002Fcode> compiles to \u003Ccode>string\u003C\u002Fcode>, and the\nconsumer&#39;s checker still sees \u003Ccode>bytes\u003C\u002Fcode>:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">namespace\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> App\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">use\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> Acme\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">\\\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">;\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan style=\"--phn-light:#8F5E00;--phn-dark:#F2B43F\">function\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> label\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\">Money\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\"> $price\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">):\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#0D5F78;--phn-dark:#6FC3DF\"> string\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\"> =>\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\"> strtoupper\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">(\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#1F2127;--phn-dark:#E2E3E7\">$price\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">->\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#7A3D99;--phn-dark:#C9A0F0\">pack\u003C\u002Fspan>\u003Cspan style=\"--phn-light:#6A6F7D;--phn-dark:#8B91A2\">());\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>src\u002FLabel.phn:5:52: error P2103: argument 1 ($string) of strtoupper() expects string, bytes given\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>    5 | function label(Money $price): string => strtoupper($price->pack());\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>      |                                                    ^^^^^^^^^^^^^^\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>What runs is the library&#39;s committed PHP, written by the compiler the library pinned, for the\ntarget the library names. A consumer on a much newer compiler may need a newer release of the\nlibrary, if a later compiler withdrew syntax its sources use.\u003C\u002Fp>\n\u003Cp>A release that names a committed root but came without its outputs fails the dump, before any\nbinary is fetched, and nothing is built in its place:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>phaenon\u002Fphn: acme\u002Fmoney v1.0.0: its phaenon.json commits the outputs of the root src, but this release is installed without them: .src\u002FMoney.php is missing\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>A root that is not committed is built where the library is installed, if the install has it.\nThat is why the archive leaves \u003Ccode>tests\u002F\u003C\u002Fcode> out: an install from source, a git clone, has \u003Ccode>tests\u002F\u003C\u002Fcode>,\nand the plugin compiles them with warnings for the PHPUnit the consumer lacks.\u003C\u002Fp>\n\u003Ch2 id=\"shipping-sources-only\">Shipping sources only\u003Ca class=\"docs-anchor\" href=\"#shipping-sources-only\" aria-hidden=\"true\" tabindex=\"-1\">#\u003C\u002Fa>\u003C\u002Fh2>\n\u003Cp>A library without \u003Ccode>committed\u003C\u002Fcode> commits no outputs: \u003Ccode>.src\u002F\u003C\u002Fcode> is ignored, \u003Ccode>phaenon\u002Fphn\u003C\u002Fcode> stands under\n\u003Ccode>require\u003C\u002Fcode> with the range of releases its sources compile with, and the plugin builds the library\nin each project that installs it, for the library&#39;s own target, its findings printed as warnings.\nEvery consumer must then allow the plugin; a project that has not is stopped by Composer:\u003C\u002Fp>\n\u003Cfigure class=\"docs-code phn-code-surface\">\u003Cdiv class=\"docs-code-body\">\u003Cpre class=\"shiki shiki-themes phaenon-light phaenon-dark\" style=\"--phn-light:#1f2127;--phn-dark:#e2e3e7;--phn-light-bg:#f9fafb;--phn-dark-bg:#0f1115\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>  phaenon\u002Fphn contains a Composer plugin which is blocked by your allow-plugins config. You may add it to the list if you consider it safe.\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>  You can run \"composer config --no-plugins allow-plugins.phaenon\u002Fphn [true|false]\" to enable it (true) or disable it explicitly and suppress this exception (false)\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>  See https:\u002F\u002Fgetcomposer.org\u002Fallow-plugins\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fdiv>\u003C\u002Ffigure>\n\u003Cp>That is the price the committed outputs avoid.\u003C\u002Fp>\n",1794925619714]