diff options
author | zeertzjq <zeertzjq@outlook.com> | 2023-11-29 20:32:40 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-29 20:32:40 +0800 |
commit | a6cba103cebce535279db197f9efeb34e9d1171f (patch) | |
tree | 17a8d9b4ecabf8e2c02c07e18b81c85f2e7c429f /src/nvim/memfile.h | |
parent | f4001d27efae44c6c07678ad2c72eed5f1a25ea8 (diff) | |
download | rneovim-a6cba103cebce535279db197f9efeb34e9d1171f.tar.gz rneovim-a6cba103cebce535279db197f9efeb34e9d1171f.tar.bz2 rneovim-a6cba103cebce535279db197f9efeb34e9d1171f.zip |
refactor: move some constants out of vim_defs.h (#26298)
Diffstat (limited to 'src/nvim/memfile.h')
-rw-r--r-- | src/nvim/memfile.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/nvim/memfile.h b/src/nvim/memfile.h index 2d1930e95c..687ac042a4 100644 --- a/src/nvim/memfile.h +++ b/src/nvim/memfile.h @@ -11,6 +11,15 @@ enum { MFS_ZERO = 8, ///< only write block 0 }; +enum { + /// Minimal size for block 0 of a swap file. + /// NOTE: This depends on size of struct block0! It's not done with a sizeof(), + /// because struct block0 is defined in memline.c (Sorry). + /// The maximal block size is arbitrary. + MIN_SWAP_PAGE_SIZE = 1048, + MAX_SWAP_PAGE_SIZE = 50000, +}; + #ifdef INCLUDE_GENERATED_DECLARATIONS # include "memfile.h.generated.h" #endif |