Help for this page

Select Code to Download


  1. or download this
        $shared .= <PIPE>;
    
  2. or download this
        my $local = <PIPE>;
        $shared .= $local;
    
  3. or download this
        my $local = <PIPE>;
        { lock( $shared ); $shared = $local; }
    
  4. or download this
    { 
        lock( $shared );
        my $local = <PIPE>;
        $shared = $local; 
    }
    
  5. or download this
    # XXX. The key and value are related.
    my $string = $shared_key . ' => ' . $shared_value;
    
  6. or download this
    C:\test>perl -MO=Terse
    my $string = $shared_key . ' => ' . $shared_value;
    ...
            OP (0x191dad0) padsv [1]
        ## critical section exited here.
    - syntax OK
    
  7. or download this
    {
        lock( $shared )
        $local = $shared;
        $shared = somefunction( $local );
    }
    
  8. or download this
    $shared = somefunction( $shared );
    
  9. or download this
    C:\test>perl -MO=Terse
    sub somefunction{ $_[0] + 1 }
    ...
                PADOP (0x191d964) gvsv  GV (0x22507c) *shared
        ## ExitCriticalSection here.
    - syntax OK