summaryrefslogtreecommitdiff
path: root/src/parsers/type
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-06-13 12:12:06 +0300
committerAndrei Karas <akaras@inbox.ru>2015-06-13 12:12:06 +0300
commitcad4a8a87daed1ddaeb1a4c0905f073b548b312d (patch)
treeea98cbc5fc4a5aad81522e284e2928ecaba70c00 /src/parsers/type
parent73ee70432eee4aa415f882215475e3efab9f1d4d (diff)
downloadparanucker-cad4a8a87daed1ddaeb1a4c0905f073b548b312d.tar.gz
paranucker-cad4a8a87daed1ddaeb1a4c0905f073b548b312d.tar.bz2
paranucker-cad4a8a87daed1ddaeb1a4c0905f073b548b312d.tar.xz
paranucker-cad4a8a87daed1ddaeb1a4c0905f073b548b312d.zip
Add parsing type REFERENCE_TYPE.
Diffstat (limited to 'src/parsers/type')
-rw-r--r--src/parsers/type/reference_type.cpp44
1 files changed, 44 insertions, 0 deletions
diff --git a/src/parsers/type/reference_type.cpp b/src/parsers/type/reference_type.cpp
new file mode 100644
index 0000000..0327b9b
--- /dev/null
+++ b/src/parsers/type/reference_type.cpp
@@ -0,0 +1,44 @@
+/*
+ * Copyright (C) 2015 Andrei Karas
+ *
+ * This file is part of AstDumper.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "includes/parserincludes.h"
+
+parserDefine(ReferenceType);
+
+#include "parsers/base/type.h"
+
+#include "nodes/type/reference_type.h"
+
+namespace Generic
+{
+
+void parseReferenceTypeNode(ReferenceTypeNode *node)
+{
+ fillType(node);
+ Log::dump(node);
+
+ fillTypeName(node);
+ fillTypeAttributes(node);
+ node->nestedType = static_cast<TypeNode*>(createParseNode(
+ node,
+ TREE_TYPE(node->gccNode),
+ "nested type"));
+}
+
+}