No description, website, or topics provided.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
DEBUG.pm6 s/EnumMap/Map/ Oct 11, 2015
META6.json Use SPDX identifier in license field of META6.json Apr 27, 2017
NDEBUG.pm6 add dbg macro (evaluates its argument in DEBUG mode, yields True othe… May 19, 2015
assert.pm6 fix some bitrot, but assert still warns... Apr 27, 2017
logger.pm6 fix some bitrot, but assert still warns... Apr 27, 2017


DEBUG - Experimental debugging macros


    perl6 -MDEBUG -e 'use dbg; dbg note "debugging..."'
    perl6 -MDEBUG -e 'use assert; assert 0 > 1'
    perl6 -MDEBUG -e 'use logger; logger "hello world"'
    use dbg;
    use assert &warn;
    use logger &say;

    use DEBUG;

    logger 'Printing to STDOUT...';
    dbg say 'Also prints to STDOUT...';
    assert !'Only a warning';

    use NDEBUG <logger>;

    dbg note 'Logging disabled';
    logger do {
        'This will never be executed...';

    use DEBUG <logger>;

    dbg note 'Logging enabled';
    logger 'Alive!';

Bugs and Development

Development happens at GitHub. If you found a bug or have a feature request, use the issue tracker over there.

Copyright and License

Copyright (C) 2015 by

Distributed under the Boost Software License, Version 1.0