projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
comment up the array slots
[spider.git]
/
perl
/
RingBuf.pm
diff --git
a/perl/RingBuf.pm
b/perl/RingBuf.pm
index 82b534e41d2081887c4cee814cade8dee0a4286a..e9b1052a92f8e42566b02b91aa608c6cd69c7116 100644
(file)
--- a/
perl/RingBuf.pm
+++ b/
perl/RingBuf.pm
@@
-21,6
+21,13
@@
sub new
{
my $pkg = shift;
my $size = shift;
+
+ # 0 - size
+ # 1 - lth
+ # 2 - end
+ # 3 - start
+ # 4 - pos
+ # 5 - buffer []
return bless [$size, 0, 0, 0, 0, []], (ref $pkg || $pkg);
}