Skip to content

Commit

Permalink
remove jfmt, jval, jnamval
Browse files Browse the repository at this point in the history
We remove jfmt, jval, and jnamval from the code base until they are ready
to be tested so that the general public and/or IOCCC submitters do not
become confused by these "not ready" tools and file bug reports on them.

In [GH-issuecomment-2282221142](#523 (comment))
a model based on the [JSONPath.sh](issuecomment-2282221142) command line
be considered for jfmt, jval, jnamval.

In
[GH-issuecomment-2278613143](#928 (comment))
it has been stated that jfmt, jval, jnamval are "_incomplete and will
be heavily modified and almost entirely rewritten_".  In light of the
the [JSONPath.sh](issuecomment-2282221142) command line model, the
"_entirely rewritten_" is much more likely.

Therefore we remove nearly all references to jfmt, jval, and jnamval.

We have **NOT** removed every reference to jfmt, jval, and jnamval:

- The `CHANGES.md` file will continue to contain historical references
to jfmt, jval, and jnamval.

- The `make uninstall` will continue to remove any installed binary and
man page related to jfmt, jval, and jnamval.

- The `jparse/.gitignore` file ignores the jfmt, jval, and jnamval binary
files to make it easier for future developers to work on those tools.

- The _JSON_UTIL_MATCH_TYPE_ types are left in `jparse/json_util.h`
as they related to types of JSON elements that could be matched later on.

- The `struct json_util_number_range` and `struct json_util_number`
files to make it easier for future developers to work on those tools.

- The `json_util_parse_number_range()` function in `jparse/json_util.c`
is left because it may be useful for future tools need to compare numbers.

- The `json_util_number_in_range` function in `jparse/json_util.c`
is left because it may be useful for future tools need to compare numbers.

- The `json_util_parse_st_level_option()` function in `jparse/json_util.c`
is left because it may be useful for future tools need to focus on parse
tree levels.

Performed `make release` to test the above under macOS.
  • Loading branch information
lcn2 committed Aug 11, 2024
1 parent 8acd9b0 commit 624fbb0
Show file tree
Hide file tree
Showing 32 changed files with 30 additions and 10,134 deletions.
7 changes: 7 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# Major changes to the IOCCC entry toolkit


## Release 1.3.2 2024-08-10

Removed code files and documentation related to `jfmt(1)`, `jval(1)` and `jnamval(1)`
as these tools are not yet ready for release and we do not want people to become
confused about their functionality in the interim.


## Release 1.3.1 2024-08-08

Fixed a bug where `jparse/jfmt` was printing debug messages even at debug level 0.
Expand Down
3 changes: 0 additions & 3 deletions bug_report.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,6 @@ export TOOLS="
./jparse/jsemtblgen
./jparse/jstrdecode
./jparse/jstrencode
./jparse/jfmt
./jparse/jnamval
./jparse/jval
./jparse/run_bison.sh
./jparse/run_flex.sh
./jparse/test_jparse/jnum_chk
Expand Down
80 changes: 5 additions & 75 deletions jparse/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -169,13 +169,9 @@ CFLAGS= ${C_STD} ${C_OPT} ${WARN_FLAGS} ${LDFLAGS}
# source files that are permanent (not made, nor removed)
#
C_SRC= jparse_main.c json_parse.c json_sem.c json_util.c \
jsemtblgen.c jstrdecode.c jstrencode.c util.c verge.c jfmt.c jfmt_util.c \
jfmt_test.c jval.c jval_util.c jval_test.c jnamval.c jnamval_util.c jnamval_test.c
jsemtblgen.c jstrdecode.c jstrencode.c util.c verge.c
H_SRC= jparse.h jparse_main.h jsemtblgen.h json_parse.h json_sem.h json_util.h \
jstrdecode.h jstrencode.h sorry.tm.ca.h util.h verge.h jfmt.h jfmt_util.h \
jfmt_test.h jval.h jval_util.h jval_test.h jnamval.h jnamval_util.h jnamval_test.h \
jparse.tab.ref.h

jstrdecode.h jstrencode.h sorry.tm.ca.h util.h verge.h jparse.tab.ref.h
# source files that do not conform to strict picky standards
#
LESS_PICKY_CSRC= jparse.ref.c jparse.tab.ref.c
Expand All @@ -192,8 +188,7 @@ SH_FILES= jsemcgen.sh run_bison.sh run_flex.sh

# all man pages that NOT built and NOT removed by make clobber
#
MAN1_PAGES= man/man1/jparse.1 man/man1/jstrdecode.1 man/man1/jstrencode.1 man/man1/jfmt.1 \
man/man1/jval.1 man/man1/jnamval.1
MAN1_PAGES= man/man1/jparse.1 man/man1/jstrdecode.1 man/man1/jstrencode.1
MAN3_PAGES= man/man3/jparse.3 man/man3/json_dbg.3 man/man3/json_dbg_allowed.3 \
man/man3/json_err_allowed.3 man/man3/json_warn_allowed.3 man/man3/parse_json.3 \
man/man3/parse_json_file.3 man/man3/parse_json_stream.3
Expand Down Expand Up @@ -224,9 +219,7 @@ LIB_OBJS= jparse.o jparse.tab.o json_parse.o json_sem.o json_util.o util.o

# NOTE: ${OTHER_OBJS} are objects NOT put into a library and ARE removed by make clean
#
OTHER_OBJS= verge.o jsemtblgen.o jstrdecode.o jstrencode.o jparse_main.o \
jfmt.o jfmt_test.o jfmt_util.o jnamval.o jnamval_test.o jnamval_util.o \
jval.o jval_test.o jval_util.o
OTHER_OBJS= verge.o jsemtblgen.o jstrdecode.o jstrencode.o jparse_main.o

# all intermediate files which are also removed by make clean
#
Expand Down Expand Up @@ -361,7 +354,7 @@ SH_TARGETS=

# program targets to make by all, installed by install, and removed by clobber
#
PROG_TARGETS= jparse verge jsemtblgen jstrdecode jstrencode jfmt jval jnamval
PROG_TARGETS= jparse verge jsemtblgen jstrdecode jstrencode

# include files NOT to removed by clobber
#
Expand Down Expand Up @@ -452,44 +445,6 @@ jsemtblgen.o: jsemtblgen.c jparse.tab.h
jsemtblgen: jsemtblgen.o jparse.a ../dyn_array/dyn_array.a ../dbg/dbg.a
${CC} ${CFLAGS} $^ -lm -o $@

jfmt_test.o: jfmt_test.c jfmt_test.h jfmt_test.h json_util.h json_util.c
${CC} ${CFLAGS} jfmt_test.c -c

jfmt_util.o: jfmt.c jfmt_util.h jfmt.h json_util.h json_util.c
${CC} ${CFLAGS} jfmt_util.c -c

jfmt.o: jfmt.c jfmt.h jfmt_util.h jfmt_test.h json_util.h json_util.c
${CC} ${CFLAGS} jfmt.c -c

jfmt: jfmt.o jfmt_util.o jfmt_test.o jparse.a ../dyn_array/dyn_array.a ../dbg/dbg.a
${CC} ${CFLAGS} $^ -lm -o $@

jval_test.o: jval_test.c jval_test.h jval_test.h json_util.h json_util.c
${CC} ${CFLAGS} jval_test.c -c

jval_util.o: jval_util.c jval_util.h jval_util.h json_util.h json_util.c
${CC} ${CFLAGS} jval_util.c -c

jval.o: jval.c jval.h json_util.h jval_test.h json_util.c
${CC} ${CFLAGS} jval.c -c

jval: jval.o jval_util.o jval_test.o jparse.a ../dyn_array/dyn_array.a ../dbg/dbg.a
${CC} ${CFLAGS} $^ -lm -o $@

jnamval_test.o: jnamval_test.c jnamval_test.h jnamval_test.h json_util.h json_util.c
${CC} ${CFLAGS} jnamval_test.c -c

jnamval_util.o: jnamval_util.c jnamval_util.h jnamval_util.h json_util.h json_util.c
${CC} ${CFLAGS} jnamval_util.c -c

jnamval.o: jnamval.c jnamval.h json_util.h jnamval_test.h json_util.c
${CC} ${CFLAGS} jnamval.c -c

jnamval: jnamval.o jnamval_util.o jnamval_test.o jparse.a ../dyn_array/dyn_array.a ../dbg/dbg.a
${CC} ${CFLAGS} $^ -lm -o $@



json_sem.o: json_sem.c
${CC} ${CFLAGS} json_sem.c -c

Expand Down Expand Up @@ -975,23 +930,6 @@ depend: ${ALL_CSRC}
${S} echo "${OUR_NAME}: make $@ ending"

### DO NOT CHANGE MANUALLY BEYOND THIS LINE
jfmt.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jfmt.c jfmt.h jfmt_test.h \
jfmt_util.h jparse.h jparse.tab.h json_parse.h json_sem.h json_util.h \
util.h
jfmt_test.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jfmt_test.c jfmt_test.h \
jfmt_util.h jparse.h jparse.tab.h json_parse.h json_sem.h json_util.h \
util.h
jfmt_util.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jfmt_util.c jfmt_util.h \
jparse.h jparse.tab.h json_parse.h json_sem.h json_util.h util.h
jnamval.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jnamval.c jnamval.h \
jnamval_test.h jnamval_util.h jparse.h jparse.tab.h json_parse.h \
json_sem.h json_util.h util.h
jnamval_test.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jnamval_test.c \
jnamval_test.h jnamval_util.h jparse.h jparse.tab.h json_parse.h \
json_sem.h json_util.h util.h
jnamval_util.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jnamval_util.c \
jnamval_util.h jparse.h jparse.tab.h json_parse.h json_sem.h \
json_util.h util.h
jparse.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jparse.c jparse.h \
jparse.tab.h json_parse.h json_sem.h json_util.h util.h
jparse.ref.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jparse.h jparse.ref.c \
Expand All @@ -1016,13 +954,5 @@ jstrdecode.o: ../dbg/dbg.h ../dyn_array/dyn_array.h json_parse.h \
jstrdecode.c jstrdecode.h util.h
jstrencode.o: ../dbg/dbg.h ../dyn_array/dyn_array.h json_parse.h \
jstrencode.c jstrencode.h util.h
jval.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jparse.h jparse.tab.h \
json_parse.h json_sem.h json_util.h jval.c jval.h jval_test.h \
jval_util.h util.h
jval_test.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jparse.h jparse.tab.h \
json_parse.h json_sem.h json_util.h jval_test.c jval_test.h jval_util.h \
util.h
jval_util.o: ../dbg/dbg.h ../dyn_array/dyn_array.h jparse.h jparse.tab.h \
json_parse.h json_sem.h json_util.h jval_util.c jval_util.h util.h
util.o: ../dbg/dbg.h ../dyn_array/dyn_array.h util.c util.h
verge.o: ../dbg/dbg.h ../dyn_array/dyn_array.h util.h verge.c verge.h
6 changes: 0 additions & 6 deletions jparse/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -227,12 +227,6 @@ We also provide a number of tools that are, at least in what they will do when
completed, in [json_util_README.md](json_util_README.md). But please note the
warning there that says:

<hr>
As above, please be advised that the tools `jfmt`, `jval` and `jnamval` are **VERY
INCOMPLETE** and **WILL BE HEAVILY MODIFIED**. It is also highly likely that
they will be almost **entirely rewritten** as things changed as they were first
worked on. Almost everything will be redone at this point. When this is done
this notice will be removed.
<hr>

# History
Expand Down
Loading

0 comments on commit 624fbb0

Please sign in to comment.