Scalar::Alias - Perl extention to declare lexical scalar aliases


Scalar-Alias documentation  | view source Contained in the Scalar-Alias distribution.

Index


NAME

Top

Scalar::Alias - Perl extention to declare lexical scalar aliases

VERSION

Top

This document describes Scalar::Alias version 0.06.

SYNOPSIS

Top

	use Scalar::Alias;

	sub inc{
		my alias $x = shift;
		$x++;
		return;
	}

	my $i = 0;
	inc($i);
	print $i, "\n"; # => 1

	my %h;
	my alias $foo = $h{foo};

	# %h is empty

	$foo = 10;

	# %h is {foo => 10}




DESCRIPTION

Top

Scalar::Alias allows you to declare lexical scalar aliases.

There are many modules that provides variable aliases, but this module is faster than any other alias modules, because it walks into compiled syntax trees and inserts custom opcodes into the syntax tree in order to alias variables.

DEPENDENCIES

Top

Perl 5.8.1 or later, and a C compiler.

BUGS

Top

No bugs have been reported.

Please report any bugs or feature requests to the author.

SEE ALSO

Top

Lexical::Types.

"lexical aliases" in perltodo.

Other alias modules:

Lexical::Alias.

Lexical::Util

Devel::LexAlias.

Tie::Alias.

Variable::Alias.

Data::Alias.

AUTHOR

Top

Goro Fuji (gfx) <gfuji(at)cpan.org>.

LICENSE AND COPYRIGHT

Top


Scalar-Alias documentation  | view source Contained in the Scalar-Alias distribution.