// file: lxn_cstr_0.cc
//

// isip include files
//
#include "lex_node.h"
#include "lex_node_constants.h"

// method: destructor
//
// arguments: none
//
// return: none
//
// this is the default destructor
//
Lex_node::~Lex_node() {

  // delete the child link list
  //
  if (child_d != (Link_list*)NULL) {
    delete child_d;
    child_d = (Link_list*)NULL;
  }
  
  // delete the word list
  //
  if (words_d != (Link_list*)NULL) {
    delete words_d;
    words_d = (Link_list*)NULL;
  }

  // reset the scalars
  //
  phone_d = LXN_NULL_PHONE;
  score_d = LXN_LM_SCORE;
  word_end_d = ISIP_FALSE;
  type_d = LXN_WORDGRAPH;

  // exit gracefully
  //
}
