From b48970f971f74518cabffc4f033e38571b6c1da1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Wed, 30 Sep 2020 11:02:10 +0200 Subject: [PATCH] text: mark text_delete_range range argument as const --- text.c | 2 +- text.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/text.c b/text.c index 7357cf2..88b0f3b 100644 --- a/text.c +++ b/text.c @@ -1333,7 +1333,7 @@ bool text_delete(Text *txt, size_t pos, size_t len) { return true; } -bool text_delete_range(Text *txt, Filerange *r) { +bool text_delete_range(Text *txt, const Filerange *r) { if (!text_range_valid(r)) return false; return text_delete(txt, r->start, text_range_size(r)); diff --git a/text.h b/text.h index adac79b..f5a6993 100644 --- a/text.h +++ b/text.h @@ -155,7 +155,7 @@ bool text_insert(Text*, size_t pos, const char *data, size_t len); * @return Whether the deletion succeeded. */ bool text_delete(Text*, size_t pos, size_t len); -bool text_delete_range(Text*, Filerange*); +bool text_delete_range(Text*, const Filerange*); bool text_printf(Text*, size_t pos, const char *format, ...) __attribute__((format(printf, 3, 4))); bool text_appendf(Text*, const char *format, ...) __attribute__((format(printf, 2, 3))); /** -- 2.11.4.GIT