mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 04:43:10 +00:00
Remove tokenizer_test target and codeT
This commit is contained in:
parent
d43c803bfe
commit
ccb157c7a3
2 changed files with 1 additions and 50 deletions
10
Makefile.in
10
Makefile.in
|
@ -767,14 +767,6 @@ set_color: set_color.o print_help.o common.o color.o wutil.o
|
|||
$(CXX) set_color.o print_help.o common.o wutil.o color.o $(LDFLAGS_SET_COLOR) -o $@
|
||||
|
||||
|
||||
#
|
||||
# Test program for the tokenizer library
|
||||
#
|
||||
|
||||
tokenizer_test: tokenizer.cpp tokenizer.h wutil.o common.o
|
||||
$(CXX) $(CXXFLAGS) tokenizer.cpp wutil.o common.o -D TOKENIZER_TEST $(LDFLAGS) -o $@
|
||||
|
||||
|
||||
#
|
||||
# Build the fish_indent program.
|
||||
#
|
||||
|
@ -869,7 +861,7 @@ clean:
|
|||
rm -f *.o doc.h doc.tmp doc_src/*.doxygen doc_src/*.cpp doc_src/*.o doc_src/commands.hdr
|
||||
rm -f $(GENERATED_INTERN_SCRIPT_FILES)
|
||||
rm -f tests/tmp.err tests/tmp.out tests/tmp.status tests/foo.txt
|
||||
rm -f $(PROGRAMS) fish_tests tokenizer_test key_reader
|
||||
rm -f $(PROGRAMS) fish_tests key_reader
|
||||
rm -f command_list.txt toc.txt
|
||||
rm -f doc_src/index.hdr doc_src/commands.hdr
|
||||
rm -f fish-@PACKAGE_VERSION@.tar
|
||||
|
|
|
@ -747,44 +747,3 @@ bool move_word_state_machine_t::consume_char(wchar_t c)
|
|||
return consumed;
|
||||
}
|
||||
|
||||
|
||||
#ifdef TOKENIZER_TEST
|
||||
|
||||
/**
|
||||
This main function is used for compiling the tokenizer_test command, used for testing the tokenizer.
|
||||
*/
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
tokenizer tok;
|
||||
int i;
|
||||
for (i=1; i<argc; i++)
|
||||
{
|
||||
wprintf(L"Tokenizing string %s\n", argv[i]);
|
||||
for (tok_init(&tok, str2wcs(argv[i]), 0); tok_has_next(&tok); tok_next(&tok))
|
||||
{
|
||||
switch (tok_last_type(&tok))
|
||||
{
|
||||
case TOK_INVALID:
|
||||
wprintf(L"Type: INVALID\n");
|
||||
break;
|
||||
case TOK_STRING:
|
||||
wprintf(L"Type: STRING\t Value: %ls\n", tok_last(&tok));
|
||||
break;
|
||||
case TOK_PIPE:
|
||||
wprintf(L"Type: PIPE\n");
|
||||
break;
|
||||
case TOK_END:
|
||||
wprintf(L"Type: END\n");
|
||||
break;
|
||||
case TOK_ERROR:
|
||||
wprintf(L"Type: ERROR\n");
|
||||
break;
|
||||
default:
|
||||
wprintf(L"Type: Unknown\n");
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue