comparison mercurial/helptext/internals/dirstate-v2.txt @ 48189:6e01bcd111d2

dirstate-v2: Swap the order of size and mtime on disk This makes the dirstate-v2 file format match dirstate-v1 for the order of `mode`, `size`, and `mtime`. This order does not matter as long as these components are handled through named fields/attributes in code, but in a few places we still have tuples so having the same order everywhere might help avoid a bug that might not be obvious since those components have the same type. Differential Revision: https://phab.mercurial-scm.org/D11620
author Simon Sapin <simon.sapin@octobus.net>
date Fri, 08 Oct 2021 12:57:24 +0200
parents 77fc340acad7
children a5a673ec8f6f
comparison
equal deleted inserted replaced
48188:77fc340acad7 48189:6e01bcd111d2
422 Otherwise, a 32-bit integer for the Unix mode (as in `stat_result.st_mode`) 422 Otherwise, a 32-bit integer for the Unix mode (as in `stat_result.st_mode`)
423 expected for this file to be considered clean. 423 expected for this file to be considered clean.
424 Only the `S_IXUSR` bit (owner has execute permission) is considered. 424 Only the `S_IXUSR` bit (owner has execute permission) is considered.
425 425
426 * Offset 35: 426 * Offset 35:
427 If `HAS_MODE_AND_SIZE` is unset, four zero bytes.
428 Otherwise, a 32-bit integer for expected size of the file
429 truncated to its 31 least-significant bits.
430 Unlike in dirstate-v1, negative values are not used.
431
432 * Offset 39:
427 If `HAS_MTIME` is unset, four zero bytes. 433 If `HAS_MTIME` is unset, four zero bytes.
428 Otherwise, a 32-bit integer for expected modified time of the file 434 Otherwise, a 32-bit integer for expected modified time of the file
429 (as in `stat_result.st_mtime`), 435 (as in `stat_result.st_mtime`),
430 truncated to its 31 least-significant bits.
431 Unlike in dirstate-v1, negative values are not used.
432
433 * Offset 39:
434 If `HAS_MODE_AND_SIZE` is unset, four zero bytes.
435 Otherwise, a 32-bit integer for expected size of the file
436 truncated to its 31 least-significant bits. 436 truncated to its 31 least-significant bits.
437 Unlike in dirstate-v1, negative values are not used. 437 Unlike in dirstate-v1, negative values are not used.
438 438
439 If an untracked node `HAS_MTIME` *unset*, this space is unused: 439 If an untracked node `HAS_MTIME` *unset*, this space is unused:
440 440