source: src/SymTab/demangler.cc@ 4084928e

ADT aaron-thesis arm-eh ast-experimental cleanup-dtors deferred_resn demangler enum forall-pointer-decay jacob/cs343-translation jenkins-sandbox new-ast new-ast-unique-expr no_list persistent-indexer pthread-emulation qualifiedEnum
Last change on this file since 4084928e was d1e0979, checked in by Rob Schluntz <rschlunt@…>, 7 years ago

Add a basic demangler that works for basic types, pointers, tuples, and functions

  • Property mode set to 100644
File size: 456 bytes
Line 
1#include "Mangler.h"
2#include <iostream>
3#include <fstream>
4using namespace std;
5
6void f(const std::string & mangleName) {
7 cout << mangleName << " => " << std::flush << cforall_demangle(mangleName) << endl;
8}
9
10int main() {
11 ifstream in("in-demangle.txt");
12 std::string line;
13 while (getline(in, line)) {
14 if (line.empty()) { cout << "=================================" << endl; continue; }
15 else if (line[0] == '#') continue;
16 f(line);
17 }
18}
Note: See TracBrowser for help on using the repository browser.