commit 6d2af93ffb9ebdae7d4712923e50f858574c7714 Author: Laslo Hunhold <d...@frign.de> AuthorDate: Fri Jun 17 00:02:19 2022 +0200 Commit: Laslo Hunhold <d...@frign.de> CommitDate: Fri Jun 17 00:02:19 2022 +0200
Remove some testing residue The fragment in src/line.c was the untailored-number-break-check, which sadly wasn't the one the test-cases were assuming. As mentioned previously, this check would've in fact allowed to implement a grapheme_is_line_break()-function. Signed-off-by: Laslo Hunhold <d...@frign.de> diff --git a/Makefile b/Makefile index 84694e6..f6ebe06 100644 --- a/Makefile +++ b/Makefile @@ -213,7 +213,7 @@ dist: cp $(MAN3) $(MAN7) "libgrapheme-$(VERSION)/man" cp $(SRC:=.c) src/util.h "libgrapheme-$(VERSION)/src" cp $(TEST:=.c) test/util.c test/util.h "libgrapheme-$(VERSION)/test" - tar -cf - "libgrapheme-$(VERSION)" | gzip -c > "libgrapheme-$(VERSION).tar.bz2" + tar -cf - "libgrapheme-$(VERSION)" | gzip -c > "libgrapheme-$(VERSION).tar.gz" rm -rf "libgrapheme-$(VERSION)" .PHONY: all benchmark test install uninstall clean clean-data dist diff --git a/src/line.c b/src/line.c index 3dcd271..2a5623d 100644 --- a/src/line.c +++ b/src/line.c @@ -439,43 +439,6 @@ next_line_break(const void *str, size_t len, size_t (*get_codepoint) continue; } -#if 0 - if ((last_non_cm_or_zwj_prop == LINE_BREAK_PROP_CL && - cp1_prop == LINE_BREAK_PROP_PO) || - ((last_non_cm_or_zwj_prop == LINE_BREAK_PROP_CP_WITHOUT_EAW_HWF || - last_non_cm_or_zwj_prop == LINE_BREAK_PROP_CP_WITH_EAW_HWF) && - cp1_prop == LINE_BREAK_PROP_PO) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_CL && - cp1_prop == LINE_BREAK_PROP_PR) || - ((last_non_cm_or_zwj_prop == LINE_BREAK_PROP_CP_WITHOUT_EAW_HWF || - last_non_cm_or_zwj_prop == LINE_BREAK_PROP_CP_WITH_EAW_HWF) && - cp1_prop == LINE_BREAK_PROP_PR) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_NU && - cp1_prop == LINE_BREAK_PROP_PO) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_NU && - cp1_prop == LINE_BREAK_PROP_PR) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_PO && - (cp1_prop == LINE_BREAK_PROP_OP_WITHOUT_EAW_HWF || - cp1_prop == LINE_BREAK_PROP_OP_WITH_EAW_HWF)) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_PO && - cp1_prop == LINE_BREAK_PROP_NU) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_PR && - (cp1_prop == LINE_BREAK_PROP_OP_WITHOUT_EAW_HWF || - cp1_prop == LINE_BREAK_PROP_OP_WITH_EAW_HWF)) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_PR && - cp1_prop == LINE_BREAK_PROP_NU) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_HY && - cp1_prop == LINE_BREAK_PROP_NU) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_IS && - cp1_prop == LINE_BREAK_PROP_NU) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_NU && - cp1_prop == LINE_BREAK_PROP_NU) || - (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_SY && - cp1_prop == LINE_BREAK_PROP_NU)) { - continue; - } -#endif - /* LB26 */ if (last_non_cm_or_zwj_prop == LINE_BREAK_PROP_JL && (cp1_prop == LINE_BREAK_PROP_JL ||