YAML::PP::Common(3) User Contributed Perl Documentation YAML::PP::Common(3)

# [NAME](#NAME)

YAML::PP::Common - Constants and common functions

# [SYNOPSIS](#SYNOPSIS)

```
    use YAML::PP::Common ':STYLES';
    # or
    use YAML::PP::Common qw/
        YAML_ANY_SCALAR_STYLE YAML_PLAIN_SCALAR_STYLE
        YAML_SINGLE_QUOTED_SCALAR_STYLE YAML_DOUBLE_QUOTED_SCALAR_STYLE
        YAML_LITERAL_SCALAR_STYLE YAML_FOLDED_SCALAR_STYLE
        YAML_QUOTED_SCALAR_STYLE
        YAML_ANY_SEQUENCE_STYLE
        YAML_BLOCK_SEQUENCE_STYLE YAML_FLOW_SEQUENCE_STYLE
        YAML_ANY_MAPPING_STYLE
        YAML_BLOCK_MAPPING_STYLE YAML_FLOW_MAPPING_STYLE
    /;
    use YAML::PP::Common ':PRESERVE';
    # or
    use YAML::PP::Common qw/
        PRESERVE_ALL PRESERVE_ORDER PRESERVE_SCALAR_STYLE PRESERVE_FLOW_STYLE
        PRESERVE_ALIAS
    /:
```

# [DESCRIPTION](#DESCRIPTION)

This module provides common constants and functions for modules working with YAML::PP events.

# [FUNCTIONS](#FUNCTIONS)

[event\_to\_test\_suite](#event_to_test_suite)

```
    my $string = YAML::PP::Common::event_to_test_suite($event_prom_parser);
    
```

For examples of the returned format look into this distributions's directory "yaml-test-suite" which is a copy of &lt;https://github.com/yaml/yaml-test-suite&gt;.

[test\_suite\_to\_event](#test_suite_to_event)

```
    my $event = YAML::PP::Common::test_suite_to_event($str);
    
```

Turns an event string in test suite format into an event hashref. Not complete yet.

2026-10-13 perl v5.44.0

---

Document: YAML::PP::Common(3pm) from perl-yaml-pp 0.43.0-r0 (Chainguard OS)
Source: https://github.com/perlpunk/YAML-PP-p5.git
