Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Kirill Smelkov
wendelin.core
Commits
25748d7e
Commit
25748d7e
authored
Aug 04, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
03c1da81
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
6 deletions
+3
-6
wcfs/internal/zdata/δftail.go
wcfs/internal/zdata/δftail.go
+3
-3
wcfs/internal/zdata/δftail_test.go
wcfs/internal/zdata/δftail_test.go
+0
-3
No files found.
wcfs/internal/zdata/δftail.go
View file @
25748d7e
...
...
@@ -521,7 +521,7 @@ func (δftail *_ΔFileTail) forgetPast(revCut zodb.Tid) {
//
// Note: contrary to regular go slicing, low is exclusive while high is inclusive.
func
(
δFtail
*
ΔFtail
)
SliceByFileRev
(
zfile
*
ZBigFile
,
lo
,
hi
zodb
.
Tid
)
/*readonly*/
[]
*
ΔFile
{
fmt
.
Printf
(
"
\n
slice f<%s> (@%s,@%s]
\n
"
,
zfile
.
POid
(),
lo
,
hi
)
//
fmt.Printf("\nslice f<%s> (@%s,@%s]\n", zfile.POid(), lo, hi)
xtail
.
AssertSlice
(
δFtail
,
lo
,
hi
)
// XXX locking
...
...
@@ -639,7 +639,7 @@ func (δFtail *ΔFtail) SliceByFileRev(zfile *ZBigFile, lo, hi zodb.Tid) /*reado
if
iz
>=
0
&&
vδZ
[
iz
]
.
Rev
>
epoch
{
δZ
:=
vδZ
[
iz
]
if
ZinblkAt
<=
δZ
.
Rev
{
fmt
.
Printf
(
"δZ @%s
\n
"
,
δZ
.
Rev
)
//
fmt.Printf("δZ @%s\n", δZ.Rev)
for
_
,
oid
:=
range
δZ
.
Changev
{
inblk
,
ok
:=
Zinblk
[
oid
]
if
ok
&&
len
(
inblk
)
!=
0
{
...
...
@@ -655,7 +655,7 @@ func (δFtail *ΔFtail) SliceByFileRev(zfile *ZBigFile, lo, hi zodb.Tid) /*reado
// δT -> adjust Zinblk + update δf
if
it
>=
0
{
δT
:=
vδT
[
it
]
fmt
.
Printf
(
"δT @%s
\n
"
,
δT
.
Rev
)
//
fmt.Printf("δT @%s\n", δT.Rev)
for
blk
,
δzblk
:=
range
δT
.
ΔKV
{
// apply in reverse as we go ←
if
δzblk
.
New
!=
xbtree
.
VDEL
{
...
...
wcfs/internal/zdata/δftail_test.go
View file @
25748d7e
...
...
@@ -542,7 +542,6 @@ func testΔFtail(t_ *testing.T, testq chan ΔFTestEntry) {
}
/*
// SliceByFileRev
for
j
:=
0
;
j
<
len
(
vδf
);
j
++
{
for
k
:=
j
;
k
<
len
(
vδf
);
k
++
{
...
...
@@ -561,8 +560,6 @@ func testΔFtail(t_ *testing.T, testq chan ΔFTestEntry) {
}
}
}
*/
_
=
vδfstr
// BlkRevAt
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment