Commit d6cc2c40 authored by Benno Schulenberg's avatar Benno Schulenberg
Browse files

tweaks: conditionalize a function that is not used in the tiny version

The fsfromline() function is mostly used by the undo functions, which
are not present in the tiny version.  It is also used by the comment/
uncomment feature, but this feature cannot be enabled when --enable-tiny
is in effect.
No related merge requests found
Showing with 4 additions and 0 deletions
+4 -0
......@@ -697,7 +697,9 @@ bool comment_line(undo_type action, filestruct *f, const char *comment_seq);
#endif
#endif
size_t get_totsize(const filestruct *begin, const filestruct *end);
#ifndef NANO_TINY
filestruct *fsfromline(ssize_t lineno);
#endif
#ifdef DEBUG
void dump_filestruct(const filestruct *inptr);
void dump_filestruct_reverse(void);
......
......@@ -617,6 +617,7 @@ size_t get_totsize(const filestruct *begin, const filestruct *end)
return totsize;
}
#ifndef NANO_TINY
/* Given a line number, return a pointer to the corresponding struct. */
filestruct *fsfromline(ssize_t lineno)
{
......@@ -637,6 +638,7 @@ filestruct *fsfromline(ssize_t lineno)
return f;
}
#endif
#ifdef DEBUG
/* Dump the filestruct inptr to stderr. */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment