summaryrefslogtreecommitdiff
path: root/src/parsers
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-06-12 19:34:48 +0300
committerAndrei Karas <akaras@inbox.ru>2015-06-12 19:34:48 +0300
commit09d1424e62b04bd75d90af78f49d08c9e366ddc8 (patch)
tree130d009471fb2f3d9279feb094965c9cf9a8969c /src/parsers
parent1457bb363f7c0bc80a04deff194a3d03978b501c (diff)
downloadparanucker-09d1424e62b04bd75d90af78f49d08c9e366ddc8.tar.gz
paranucker-09d1424e62b04bd75d90af78f49d08c9e366ddc8.tar.bz2
paranucker-09d1424e62b04bd75d90af78f49d08c9e366ddc8.tar.xz
paranucker-09d1424e62b04bd75d90af78f49d08c9e366ddc8.zip
Add parsing node VECTOR_CST.
Diffstat (limited to 'src/parsers')
-rw-r--r--src/parsers/cst/vector_cst.cpp45
1 files changed, 45 insertions, 0 deletions
diff --git a/src/parsers/cst/vector_cst.cpp b/src/parsers/cst/vector_cst.cpp
new file mode 100644
index 0000000..8d874a4
--- /dev/null
+++ b/src/parsers/cst/vector_cst.cpp
@@ -0,0 +1,45 @@
+/*
+ * 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(VectorCst);
+
+
+#include "nodes/cst/vector_cst.h"
+
+namespace Generic
+{
+
+void parseVectorCstNode(VectorCstNode *node)
+{
+ fillType(node);
+ Log::dump(node);
+
+ const int sz = VECTOR_CST_NELTS(node->gccNode);
+ for (int f = 0; f < sz; f ++)
+ {
+ node->args.push_back(createParseNode(
+ node,
+ VECTOR_CST_ELT(node->gccNode, f),
+ "element"));
+ }
+}
+
+}