Up to [cvs.NetBSD.org] / src / lib / libedit
Request diff between arbitrary revisions
Default branch: MAIN
Current tag: localcount-20160914
Revision 1.47 / (download) - annotate - [select for diffs], Sun May 22 19:44:26 2016 UTC (7 years, 10 months ago) by christos
Branch: MAIN
CVS Tags: prg-localcount2-base3,
prg-localcount2-base2,
prg-localcount2-base1,
prg-localcount2-base,
prg-localcount2,
pgoyette-localcount-base,
pgoyette-localcount-20170426,
pgoyette-localcount-20170320,
pgoyette-localcount-20170107,
pgoyette-localcount-20161104,
pgoyette-localcount-20160806,
pgoyette-localcount-20160726,
pgoyette-localcount,
perseant-stdc-iso10646-base,
perseant-stdc-iso10646,
netbsd-8-base,
netbsd-8-2-RELEASE,
netbsd-8-1-RELEASE,
netbsd-8-1-RC1,
netbsd-8-0-RELEASE,
netbsd-8-0-RC2,
netbsd-8-0-RC1,
netbsd-8,
matt-nb8-mediatek-base,
matt-nb8-mediatek,
localcount-20160914,
bouyer-socketcan-base1,
bouyer-socketcan-base,
bouyer-socketcan
Changes since 1.46: +3 -3
lines
Diff to previous 1.46 (colored)
Stop the read module from poking the el_chared.c_macro data structure currently belonging to the chared module. The read module does so from three of its functions, while no other module uses the macro data, not even the chared module itself. That's quite logical because macros are a feature of input handling, all of which is done by the read module, and none by the chared module. So move the data into the read modules's own opaque data structure, struct el_read_t. That simplifies internal interfaces in several respects: The semi-public chared.h has one fewer struct, one fewer #define, and one fewer member in struct el_chared_t; all three move to one single C file, read.c, and are now module-local. And the internal interface function ch_reset() needs one fewer argument, making the code of many functions in various modules more readable. The price is one additional internal interface function, read_end(), 10 lines long including comments, called publicly from exactly one place: el_end() in el.c. That's hardly an increase in complexity since most other modules already have their *_end() function, read.c was the odd one out not having one. From Ingo Schwarze