diff options
Diffstat (limited to 'lib/Config/AST/Follow.pm')
-rw-r--r-- | lib/Config/AST/Follow.pm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Config/AST/Follow.pm b/lib/Config/AST/Follow.pm index 84d6a3d..4d996a5 100644 --- a/lib/Config/AST/Follow.pm +++ b/lib/Config/AST/Follow.pm @@ -121,4 +121,13 @@ sub AUTOLOAD { sub DESTROY { } +use overload + bool => sub { !!shift->{_node} }, + '""' => sub { shift->{_node}->as_string }, + eq => sub { + my ($self,$other) = @_; + return $self->{_node}->as_string eq $other + }; + + 1; |