---
name: "Aspect::Pointcut::Wantarray"
section: "3pm"
platform: "linux"
package: "libaspect-perl"
version: "1.04-3"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/Aspect::Pointcut::Wantarray"
---

# Aspect::Pointcut::Wantarray(3pm)

A pointcut for the run-time wantarray context

## NAME

Aspect::Pointcut::Wantarray - A pointcut for the run-time wantarray context

## SYNOPSIS

```
  use Aspect;

  # High-level creation
  my $pointcut1 = wantlist | wantscalar | wantvoid;

  # Manual creation
  my $pointcut2 = Padre::Pointcut::Or->new(
    Padre::Pointcut::Wantarray->new( 1 ),     # List
    Padre::Pointcut::Wantarray->new( 0 ),     # Scalar
    Padre::Pointcut::Wantarray->new( undef ), # Void
  );
```

## DESCRIPTION

The `"Aspect::Pointcut::Wantarray"` pointcut allows the creation of aspects that only trap calls made in a particular calling context (list, scalar or void).

## AUTHORS

Adam Kennedy \<adamk@cpan.org\>

## COPYRIGHT

Copyright 2001 by Marcel Grünauer

Some parts copyright 2009 - 2013 Adam Kennedy.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
