Skip to content

Commit

Permalink
Added documentation for isnull()
Browse files Browse the repository at this point in the history
  • Loading branch information
run4flat committed Aug 9, 2012
1 parent 17019f6 commit 7bcf2dd
Showing 1 changed file with 19 additions and 3 deletions.
22 changes: 19 additions & 3 deletions Basic/Core/Core.pm.PL
Expand Up @@ -2539,9 +2539,25 @@ sub PDL::new_from_specification{
return $pdl;
}
# is there such a beast?
# L<PDL::Primitive::isnull|PDL::Primitive/isnull>
#
=head2 isnull
=for ref
Test whether a piddle is null
=for usage
croak("Input piddle mustn't be null!")
if $input_piddle->isnull;
This function returns 1 if the piddle is null, zero if it is not. The purpose
of null piddles is to "tell" any PDL::PP methods to allocate new memory for
an output piddle, but only when that PDL::PP method is called in full-arg
form. Of course, there's no reason you couldn't commandeer the special value
for your own purposes, for which this test function would prove most helpful.
But in general, you shouldn't need to test for a piddle's nullness.
See L</Null PDLs> for more information.
=head2 isempty
Expand Down

0 comments on commit 7bcf2dd

Please sign in to comment.