mirror of
https://github.com/rkd77/elinks.git
synced 2024-09-12 00:34:47 -04:00
set_hline: Define local variables as const where possible.
I hope this makes the source easier to understand.
This commit is contained in:
parent
ad25b348be
commit
6b68d38131
@ -386,14 +386,14 @@ static inline int
|
|||||||
set_hline(struct html_context *html_context, unsigned char *chars, int charslen,
|
set_hline(struct html_context *html_context, unsigned char *chars, int charslen,
|
||||||
enum link_state link_state)
|
enum link_state link_state)
|
||||||
{
|
{
|
||||||
struct part *part = html_context->part;
|
struct part *const part = html_context->part;
|
||||||
struct screen_char *schar = get_format_screen_char(html_context,
|
struct screen_char *const schar = get_format_screen_char(html_context,
|
||||||
link_state);
|
link_state);
|
||||||
int x = part->cx;
|
int x = part->cx;
|
||||||
int y = part->cy;
|
const int y = part->cy;
|
||||||
int x2 = x;
|
const int x2 = x;
|
||||||
int len = charslen;
|
int len = charslen;
|
||||||
int utf8 = html_context->options->utf8;
|
const int utf8 = html_context->options->utf8;
|
||||||
|
|
||||||
assert(part);
|
assert(part);
|
||||||
if_assert_failed return len;
|
if_assert_failed return len;
|
||||||
|
Loading…
Reference in New Issue
Block a user