You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have a merge bug in our code, given the following example
`
const strBase = '{"enabled":false}';
const strLeft = '{"enabled":true,"other":1}';
const strRight = '{"enabled":true}';
const merged = merge(strLeft, strBase, strRight);
assert.equal(merged.conflict, false,
'has no merge conflicts');
We have a merge bug in our code, given the following example
`
const strBase = '{"enabled":false}';
const strLeft = '{"enabled":true,"other":1}';
const strRight = '{"enabled":true}';
const merged = merge(strLeft, strBase, strRight);
assert.equal(merged.conflict, false,
'has no merge conflicts');
`
Output
actual: > {"enabled":truetrue,"other":1} expected: > {"enabled":true,"other":1}
This error steems from this line
https://github.com/movableink/three-way-merge/blob/master/src/merger.ts#L69
As multiple intersected ranges from right are taken into final result. In our case the same 'true' token is taken several times from right array.
Possible solution
#4
The text was updated successfully, but these errors were encountered: