# HG changeset patch # User John W. Eaton # Date 1294603051 18000 # Node ID 7aab48b6e903f6b4e842f0acfb556ae63955584e # Parent 1f64a7b73e982a3a528b0f23340e5fc896096dfe token.h, token.cc: delete obsolete and unused token type diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,11 @@ +2011-01-09 John W. Eaton + + * token.h, token.cc (token::plot_tok_typ): Delete unused enum. + (token::token_type): Delete pttype_token from the list. + (token::token (plot_tok_type, int, int)): Delete unused constructor. + (token::pttype): Delete unused function. + (token::anonymous union): Delete PT element. + 2011-01-09 John W. Eaton * lex.ll (display_token): Display token value for NUM, IMAG_NUM, diff --git a/src/token.cc b/src/token.cc --- a/src/token.cc +++ b/src/token.cc @@ -65,14 +65,6 @@ et = t; } -token::token (plot_tok_type t, int l, int c) -{ - line_num = l; - column_num = c; - type_tag = pttype_token; - pt = t; -} - token::token (symbol_table::symbol_record *s, int l, int c) { line_num = l; @@ -130,13 +122,6 @@ return et; } -token::plot_tok_type -token::pttype (void) -{ - assert (type_tag == pttype_token); - return pt; -} - symbol_table::symbol_record * token::sym_rec (void) { diff --git a/src/token.h b/src/token.h --- a/src/token.h +++ b/src/token.h @@ -37,7 +37,6 @@ string_token, double_token, ettype_token, - pttype_token, sym_rec_token, scls_rec_token, meta_rec_token @@ -59,19 +58,11 @@ unwind_protect_end }; - enum plot_tok_type - { - replot = 1, - two_dee = 2, - three_dee = 3 - }; - token (int l = -1, int c = -1); token (const std::string& s, int l = -1, int c = -1); token (double d, const std::string& s = std::string (), int l = -1, int c = -1); token (end_tok_type t, int l = -1, int c = -1); - token (plot_tok_type t, int l = -1, int c = -1); token (symbol_table::symbol_record *s, int l = -1, int c = -1); token (symbol_table::symbol_record *cls, symbol_table::symbol_record *pkg, int l = -1, int c = -1); @@ -87,7 +78,6 @@ std::string text (void); double number (void); end_tok_type ettype (void); - plot_tok_type pttype (void); symbol_table::symbol_record *sym_rec (void); symbol_table::symbol_record *method_rec (void); @@ -115,7 +105,6 @@ std::string *str; double num; end_tok_type et; - plot_tok_type pt; symbol_table::symbol_record *sr; struct {