Michael Campbell wrote:

>On Tue, 1 Jun 2004 20:53:47 +0900, orbit <orbit / klientsky.ru> wrote:
>  
>
>>orbit / klientsky.ru (orbit) wrote in message news:<734420e9.0405310551.2526ea0 / posting.google.com>...
>>    
>>
>>>Whot can I set value for variable which name cosist ather variable?
>>>
>>>var1 = "@var2"
>>>      
>>>
>>I want, that as in Perl was
>>cat p1.pl
>>
>>#!/usr/bin/perl
>>
>>$foo = "xo-xo";
>>print "1 - foo = $foo\n";
>>$scalarref = \$foo;
>>$$scalarref = "xe-xe";
>>print "2 - foo = $foo\n";
>>
>>../p1.pl
>>1 - foo = xo-xo
>>2 - foo = xe-xe
>>    
>>
>
>
>I think that even the royal perl monarchy discourage the use of
>softrefs as "bad practice", no?
>
>  
>
They do, but that example is a hard reference which isn't discouraged.

The following is a soft, or symbolic reference,

$foo = "xo-xo";
print "1 - foo = $foo\n";
$scalarref = "foo";		#"foo" rather than \$foo
$$scalarref = "xe-xe";
print "2 - foo = $foo\n";

--
Mark Sparshatt