Skip to content

Commit ecaa70e

Browse files
committed
patch 8.1.1687: the evalfunc.c file is too big
Problem: The evalfunc.c file is too big. Solution: Move testing support to a separate file.
1 parent 2898ebb commit ecaa70e

14 files changed

Lines changed: 1026 additions & 1005 deletions

Filelist

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ SRC_ALL = \
100100
src/terminal.c \
101101
src/term.h \
102102
src/termlib.c \
103+
src/testing.c \
103104
src/textprop.c \
104105
src/ui.c \
105106
src/undo.c \
@@ -224,6 +225,7 @@ SRC_ALL = \
224225
src/proto/term.pro \
225226
src/proto/terminal.pro \
226227
src/proto/termlib.pro \
228+
src/proto/testing.pro \
227229
src/proto/textprop.pro \
228230
src/proto/ui.pro \
229231
src/proto/undo.pro \

src/Make_cyg_ming.mak

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -764,6 +764,7 @@ OBJ = \
764764
$(OUTDIR)/syntax.o \
765765
$(OUTDIR)/tag.o \
766766
$(OUTDIR)/term.o \
767+
$(OUTDIR)/testing.o \
767768
$(OUTDIR)/textprop.o \
768769
$(OUTDIR)/ui.o \
769770
$(OUTDIR)/undo.o \

src/Make_morph.mak

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ SRC = arabic.c \
8181
syntax.c \
8282
tag.c \
8383
term.c \
84+
testing.c \
85+
textprop.c \
8486
ui.c \
8587
undo.c \
8688
usercmd.c \

src/Make_mvc.mak

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -773,6 +773,7 @@ OBJ = \
773773
$(OUTDIR)\syntax.obj \
774774
$(OUTDIR)\tag.obj \
775775
$(OUTDIR)\term.obj \
776+
$(OUTDIR)\testing.obj \
776777
$(OUTDIR)\textprop.obj \
777778
$(OUTDIR)\ui.obj \
778779
$(OUTDIR)\undo.obj \
@@ -1620,6 +1621,8 @@ $(OUTDIR)/tag.obj: $(OUTDIR) tag.c $(INCL)
16201621

16211622
$(OUTDIR)/term.obj: $(OUTDIR) term.c $(INCL)
16221623

1624+
$(OUTDIR)/term.obj: $(OUTDIR) testing.c $(INCL)
1625+
16231626
$(OUTDIR)/textprop.obj: $(OUTDIR) textprop.c $(INCL)
16241627

16251628
$(OUTDIR)/ui.obj: $(OUTDIR) ui.c $(INCL)
@@ -1778,6 +1781,7 @@ proto.h: \
17781781
proto/syntax.pro \
17791782
proto/tag.pro \
17801783
proto/term.pro \
1784+
proto/testing.pro \
17811785
proto/textprop.pro \
17821786
proto/ui.pro \
17831787
proto/undo.pro \

src/Make_vms.mms

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Makefile for Vim on OpenVMS
33
#
44
# Maintainer: Zoltan Arpadffy <arpadffy@polarhome.com>
5-
# Last change: 2019 May 24
5+
# Last change: 2019 Jul 14
66
#
77
# This has script been tested on VMS 6.2 to 8.2 on DEC Alpha, VAX and IA64
88
# with MMS and MMK
@@ -315,7 +315,7 @@ SRC = arabic.c autocmd.c beval.c blob.c blowfish.c buffer.c change.c charset.c \
315315
menu.c mbyte.c memfile.c memline.c message.c misc1.c misc2.c move.c \
316316
normal.c ops.c option.c popupmnu.c popupwin.c profiler.c quickfix.c \
317317
regexp.c search.c sha256.c sign.c spell.c spellfile.c syntax.c tag.c \
318-
term.c termlib.c textprop.c ui.c undo.c usercmd.c userfunc.c \
318+
term.c termlib.c testing.c textprop.c ui.c undo.c usercmd.c userfunc.c \
319319
version.c screen.c window.c os_unix.c os_vms.c pathdef.c \
320320
$(GUI_SRC) $(PERL_SRC) $(PYTHON_SRC) $(TCL_SRC) \
321321
$(RUBY_SRC) $(HANGULIN_SRC) $(MZSCH_SRC) $(XDIFF_SRC)
@@ -330,7 +330,7 @@ OBJ = arabic.obj autocmd.obj beval.obj blob.obj blowfish.obj buffer.obj change.
330330
move.obj mbyte.obj normal.obj ops.obj option.obj popupmnu.obj \
331331
popupwin.obj profiler.obj quickfix.obj regexp.obj search.obj \
332332
sha256.obj sign.obj spell.obj spellfile.obj syntax.obj tag.obj \
333-
term.obj termlib.obj textprop.obj ui.obj undo.obj usercmd.obj \
333+
term.obj termlib.obj testing.obj textprop.obj ui.obj undo.obj usercmd.obj \
334334
userfunc.obj screen.obj version.obj window.obj os_unix.obj os_vms.obj \
335335
pathdef.obj if_mzsch.obj \
336336
$(GUI_OBJ) $(PERL_OBJ) $(PYTHON_OBJ) $(TCL_OBJ) \
@@ -745,6 +745,10 @@ termlib.obj : termlib.c vim.h [.auto]config.h feature.h os_unix.h \
745745
ascii.h keymap.h term.h macros.h structs.h regexp.h gui.h beval.h \
746746
[.proto]gui_beval.pro option.h ex_cmds.h proto.h globals.h \
747747

748+
testing.obj : testing.c vim.h [.auto]config.h feature.h os_unix.h \
749+
ascii.h keymap.h term.h macros.h structs.h regexp.h gui.h beval.h \
750+
[.proto]gui_beval.pro option.h ex_cmds.h proto.h globals.h \
751+
748752
textprop.obj : textprop.c vim.h [.auto]config.h feature.h os_unix.h \
749753
ascii.h keymap.h term.h macros.h structs.h regexp.h gui.h beval.h \
750754
[.proto]gui_beval.pro option.h ex_cmds.h proto.h globals.h \

src/Makefile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1642,6 +1642,7 @@ BASIC_SRC = \
16421642
tag.c \
16431643
term.c \
16441644
terminal.c \
1645+
testing.c \
16451646
textprop.c \
16461647
ui.c \
16471648
undo.c \
@@ -1759,6 +1760,7 @@ OBJ_COMMON = \
17591760
objects/tag.o \
17601761
objects/term.o \
17611762
objects/terminal.o \
1763+
objects/testing.o \
17621764
objects/textprop.o \
17631765
objects/ui.o \
17641766
objects/undo.o \
@@ -1902,6 +1904,7 @@ PRO_AUTO = \
19021904
term.pro \
19031905
terminal.pro \
19041906
termlib.pro \
1907+
testing.pro \
19051908
textprop.pro \
19061909
ui.pro \
19071910
undo.pro \
@@ -3271,6 +3274,9 @@ objects/term.o: term.c
32713274
objects/terminal.o: terminal.c $(TERM_DEPS)
32723275
$(CCC) -o $@ terminal.c
32733276

3277+
objects/testing.o: testing.c
3278+
$(CCC) -o $@ testing.c
3279+
32743280
objects/textprop.o: textprop.c
32753281
$(CCC) -o $@ textprop.c
32763282

@@ -3702,6 +3708,10 @@ objects/terminal.o: terminal.c vim.h protodef.h auto/config.h feature.h os_unix.
37023708
proto/gui_beval.pro structs.h regexp.h gui.h alloc.h ex_cmds.h spell.h \
37033709
proto.h globals.h libvterm/include/vterm.h \
37043710
libvterm/include/vterm_keycodes.h
3711+
objects/testing.o: testing.c vim.h protodef.h auto/config.h feature.h os_unix.h \
3712+
auto/osdef.h ascii.h keymap.h term.h macros.h option.h beval.h \
3713+
proto/gui_beval.pro structs.h regexp.h gui.h alloc.h ex_cmds.h spell.h \
3714+
proto.h globals.h
37053715
objects/textprop.o: textprop.c vim.h protodef.h auto/config.h feature.h os_unix.h \
37063716
auto/osdef.h ascii.h keymap.h term.h macros.h option.h beval.h \
37073717
proto/gui_beval.pro structs.h regexp.h gui.h alloc.h ex_cmds.h spell.h \

src/README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ To jump to a file, move the cursor on its name and use the `gf` command.
2121

2222
Most code can be found in a file with an obvious name (incomplete list):
2323

24-
File name | Description
25-
--------- | -----------
24+
File name | Description
25+
--------------- | -----------
2626
autocmd.c | autocommands
2727
buffer.c | manipulating buffers (loaded files)
2828
change.c | handling changes to text
@@ -44,6 +44,8 @@ menu.c | menus
4444
message.c | (error) messages
4545
ops.c | handling operators ("d", "y", "p")
4646
option.c | options
47+
popupmnu.c | popup menu
48+
popupwin.c | popup window
4749
profiler.c | vim script profiler
4850
quickfix.c | quickfix commands (":make", ":cn")
4951
regexp.c | pattern matching
@@ -54,6 +56,8 @@ spell.c | spell checking
5456
syntax.c | syntax and other highlighting
5557
tag.c | tags
5658
term.c | terminal handling, termcap codes
59+
testing.c | testing: assert and test functions
60+
textprop.c | text properties
5761
undo.c | undo and redo
5862
usercmd.c | user defined commands
5963
userfunc.c | user defined functions

0 commit comments

Comments
 (0)