1RefElem(3) User Contributed Perl Documentation RefElem(3)
2
3
4
6 Array::RefElem - Set up array elements as aliases
7
9 use Array::RefElem qw(av_store av_push hv_store);
10
11 av_store(@a, 1, $a);
12 av_push(@a, $a);
13 hv_store(%h, $key, $a);
14
16 This module gives direct access to some of the internal Perl routines
17 that let you store things in arrays and hashes. The following
18 functions are available:
19
20 av_store(@array, $index, $value)
21 Stores $value in @array at the specified $index. After executing
22 this call, $array[$index] and $value denote the same thing.
23
24 av_push(@array, $value)
25 Pushes $value onto the @array. After executing this call,
26 $array[-1] and $value denote the same thing.
27
28 hv_store(%hash, $key, $value);
29 Stores $value in the %hash with the given $key. After executing
30 this call, $hash{$key} and $value denote the same thing.
31
33 perlguts
34
36 Copyright 2000 Gisle Aas.
37
38 This library is free software; you can redistribute it and/or modify it
39 under the same terms as Perl itself.
40
41
42
43perl v5.36.0 2023-01-19 RefElem(3)