{
    "mode": "perldoc",
    "parameter": "Type::Tiny::Manual::Installation",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/Type%3A%3ATiny%3A%3AManual%3A%3AInstallation/json",
    "generated": "2026-07-05T09:37:44Z",
    "sections": {
        "NAME": {
            "content": "Type::Tiny::Manual::Installation - how to install Type::Tiny\n",
            "subsections": []
        },
        "MANUAL": {
            "content": "Installing Type-Tiny should be straightforward.\n",
            "subsections": [
                {
                    "name": "Installation with cpanminus",
                    "content": "If you have cpanm, you only need one line:\n\n% cpanm Type::Tiny\n\nIf you are installing into a system-wide directory, you may need to pass the \"-S\" flag to cpanm,\nwhich uses sudo to install the module:\n\n% cpanm -S Type::Tiny\n"
                },
                {
                    "name": "Installation with the CPAN Shell",
                    "content": "Alternatively, if your CPAN shell is set up, you should just be able to do:\n\n% cpan Type::Tiny\n"
                },
                {
                    "name": "Manual Installation",
                    "content": "As a last resort, you can manually install it. Download the tarball and unpack it.\n\nConsult the file META.json for a list of pre-requisites. Install these first.\n\nTo build Type-Tiny:\n\n% perl Makefile.PL\n% make && make test\n\nThen install it:\n\n% make install\n\nIf you are installing into a system-wide directory, you may need to run:\n\n% sudo make install\n"
                },
                {
                    "name": "Dependencies",
                    "content": "Type::Tiny requires at least Perl 5.6.1, though certain Unicode-related features (e.g. non-ASCII\ntype constraint names) may work better in newer versions of Perl.\n\nType::Tiny requires Exporter::Tiny, a module that was previously bundled in this distribution,\nbut has since been spun off as a separate distribution. Don't worry - it's quick and easy to\ninstall.\n\nAt run-time, Type::Tiny also requires the following modules: B, B::Deparse, Carp, Data::Dumper,\nScalar::Util, Text::Balanced, overload, strict and warnings. All of these come bundled with Perl\nitself. Prior to Perl 5.8, Scalar::Util and Text::Balanced do not come bundled with Perl and\nwill need installing separately from the CPAN.\n\nCertain features require additional modules. Tying a variable to a type constraint (e.g. \"tie my\n$count, Int\") requires Type::Tie; stack traces on exceptions require Devel::StackTrace. The\nReply::Plugin::TypeTiny plugin for Reply requires Reply (obviously). Devel::LexAlias may\n*slightly* increase the speed of some of Type::Tiny's compiled coderefs.\n\nType::Tiny::XS is not required, but if available provides a speed boost for some type checks.\n(Setting the environment variable \"PERLTYPETINYXS\" to false, or setting \"PERLONLY\" to true\nwill suppress the use of Type::Tiny::XS, even if it is available.)\n\nThe test suite additionally requires Test::More, Test::Fatal and Test::Requires. Test::More\ncomes bundled with Perl, but if you are using a version of Perl older than 5.14, you will need\nto upgrade to at least Test::More version 0.96. Test::Requires and Test::Fatal (plus Try::Tiny\nwhich Test::Fatal depends on) are bundled with Type::Tiny in the \"inc\" directory, so you do not\nneed to install them separately.\n\nIf using Type::Tiny in conjunction with Moo, then at least Moo 1.006000 is recommended. If using\nType::Tiny with Moose, then at least Moose 2.0000 is recommended. If using Type::Tiny with\nMouse, then at least Mouse 1.00 is recommended. Type::Tiny is mostly untested against older\nversions of these packages.\n\nType::Tiny and cperl\ncperl <http://perl11.org/cperl/> is an extended version of Perl with various incompatible\nchanges from the official Perl 5 releases.\n\nAs of Type::Tiny 1.010001, cperl is a supported platform for Type::Tiny with some caveats. At\nthe time of writing, Moose will not install on the latest cperl releases, so using Type::Tiny\nwith Moose on cperl is untested. Moo can be forced to install, and Type::Tiny is verified to\nwork with Moo on cperl. cperl not only enables a new warnings category called \"shadow\" (which is\ngood; they're potentially useful) but switches on shadow warnings by default (which is\nannoying). Type::Tiny does not (and likely will never) attempt to work around these warnings. If\nthe warnings bother you, you should be able to catch them using $SIG{WARN}. Certain features\nof Eval::TypeTiny are broken under cperl, but they're not thought to have any practical effect\non Type::Tiny or its other bundled modules.\n"
                }
            ]
        },
        "NEXT STEPS": {
            "content": "Here's your next step:\n\n*   Type::Tiny::Manual::UsingWithMoo\n\nBasic use of Type::Tiny with Moo, including attribute type constraints, parameterized type\nconstraints, coercions, and method parameter checking.\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "Toby Inkster <tobyink@cpan.org>.\n",
            "subsections": []
        },
        "COPYRIGHT AND LICENCE": {
            "content": "This software is copyright (c) 2013-2014, 2017-2021 by Toby Inkster.\n\nThis is free software; you can redistribute it and/or modify it under the same terms as the Perl\n5 programming language system itself.\n",
            "subsections": []
        },
        "DISCLAIMER OF WARRANTIES": {
            "content": "THIS PACKAGE IS PROVIDED \"AS IS\" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING,\nWITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR\nPURPOSE.\n",
            "subsections": []
        }
    },
    "summary": "Type::Tiny::Manual::Installation - how to install Type::Tiny",
    "flags": [],
    "examples": [],
    "see_also": []
}