Skip to content

Commit ae9ec07

Browse files
authored
Add files via upload
1 parent b19ecc0 commit ae9ec07

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

BSTree.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
#include <iostream>
33
#include <algorithm>
44
#include <vector>
5+
#include <boost/lexical_cast.hpp>
56
template <class T>
67
struct BTNode
78
{
@@ -210,7 +211,7 @@ void XmlSerialize(const BTNode<T>* root, std::ostream& out = std::cout)
210211
out << "</node>";
211212
}
212213

213-
template<class T>
214+
/*template<class T>
214215
BTNode<T>* XMLDeserialize(std::istream& in = std::cin)
215216
{
216217
char x;
@@ -228,7 +229,7 @@ BTNode<T>* XMLDeserialize(std::istream& in = std::cin)
228229
std::string value;
229230
getline(in, value, '"');
230231
BTNode<T>* root = new BTNode<T>;
231-
root->data = boost::lexical_cast<T>(value);
232+
//root->data = boost::lexical_cast<T>(value);
232233
in >> x; //>
233234
getline(in, temp, '>'); //<left>
234235
root->left = XMLDeserialize<T>(in);
@@ -241,7 +242,7 @@ BTNode<T>* XMLDeserialize(std::istream& in = std::cin)
241242
return root;
242243
243244
}
244-
245+
*/
245246
int main()
246247
{
247248
auto a = build_sample_tree();

0 commit comments

Comments
 (0)