Created
August 3, 2012 05:33
-
-
Save zpmorgan/3244720 to your computer and use it in GitHub Desktop.
pdl fail regarding inplace assignment & lazy evaluation?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
use warnings; | |
use strict; | |
use PDL; | |
my $a = ones(2,2); | |
$a->inplace->minus($a*2,0); | |
print $a; | |
my $b = ones(2,2); | |
$b -= $b * 2; | |
print $b; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment