summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunghoon Park <jh9216.park@samsung.com>2019-12-03 15:23:29 +0900
committerHwankyu Jhun <h.jhun@samsung.com>2020-01-13 09:27:54 +0900
commit7f5ded85c78edd64d4e223a1297e809977442546 (patch)
treeb56fb8ed46399d9ca13d42cbc111d9a33d98119c
parent4f95a7968c7ba60433fff452cd4864bfbf01cb53 (diff)
downloadtidl-7f5ded85c78edd64d4e223a1297e809977442546.tar.gz
tidl-7f5ded85c78edd64d4e223a1297e809977442546.tar.bz2
tidl-7f5ded85c78edd64d4e223a1297e809977442546.zip
Modify folders to improve SAM score
Change-Id: Iee13089dcb077c017dd0a2d37a612d7fed7ae14f Signed-off-by: Junghoon Park <jh9216.park@samsung.com>
-rw-r--r--idlc/CMakeLists.txt14
-rw-r--r--idlc/ast/attribute.cc (renamed from idlc/attribute.cc)2
-rw-r--r--idlc/ast/attribute.h (renamed from idlc/attribute.h)0
-rw-r--r--idlc/ast/block.cc (renamed from idlc/block.cc)4
-rw-r--r--idlc/ast/block.h (renamed from idlc/block.h)2
-rw-r--r--idlc/ast/declaration.cc (renamed from idlc/declaration.cc)6
-rw-r--r--idlc/ast/declaration.h (renamed from idlc/declaration.h)4
-rw-r--r--idlc/ast/document.cc (renamed from idlc/document.cc)4
-rw-r--r--idlc/ast/document.h (renamed from idlc/document.h)2
-rw-r--r--idlc/ast/element.cc (renamed from idlc/element.cc)4
-rw-r--r--idlc/ast/element.h (renamed from idlc/element.h)4
-rw-r--r--idlc/ast/interface.cc (renamed from idlc/interface.cc)8
-rw-r--r--idlc/ast/interface.h (renamed from idlc/interface.h)6
-rw-r--r--idlc/ast/location.hh (renamed from idlc/location.hh)12
-rw-r--r--idlc/ast/parameter.cc (renamed from idlc/parameter.cc)4
-rw-r--r--idlc/ast/parameter.h (renamed from idlc/parameter.h)2
-rw-r--r--idlc/ast/parser.cc (renamed from idlc/parser.cc)16
-rw-r--r--idlc/ast/parser.h (renamed from idlc/parser.h)2
-rw-r--r--idlc/ast/position.hh (renamed from idlc/position.hh)12
-rw-r--r--idlc/ast/structure.cc (renamed from idlc/structure.cc)6
-rw-r--r--idlc/ast/structure.h (renamed from idlc/structure.h)4
-rw-r--r--idlc/ast/tidlc.ll (renamed from idlc/tidlc.ll)22
-rw-r--r--idlc/ast/tidlc.yy (renamed from idlc/tidlc.yy)22
-rw-r--r--idlc/ast/tidlc_l.cpp (renamed from idlc/tidlc_l.cpp)132
-rw-r--r--idlc/ast/tidlc_y.cpp (renamed from idlc/tidlc_y.cpp)391
-rw-r--r--idlc/ast/tidlc_y.hpp (renamed from idlc/tidlc_y.hpp)14
-rw-r--r--idlc/ast/type.cc (renamed from idlc/type.cc)2
-rw-r--r--idlc/ast/type.h (renamed from idlc/type.h)0
-rw-r--r--idlc/gen/c_body_gen_base.cc (renamed from idlc/c_gen/c_body_gen_base.cc)4
-rw-r--r--idlc/gen/c_body_gen_base.h (renamed from idlc/c_gen/c_body_gen_base.h)2
-rw-r--r--idlc/gen/c_body_gen_base_cb.h (renamed from idlc/c_gen/c_body_gen_base_cb.h)0
-rw-r--r--idlc/gen/c_gen_base.cc (renamed from idlc/c_gen/c_gen_base.cc)4
-rw-r--r--idlc/gen/c_gen_base.h (renamed from idlc/c_gen/c_gen_base.h)6
-rw-r--r--idlc/gen/c_gen_base_cb.h (renamed from idlc/c_gen/c_gen_base_cb.h)0
-rw-r--r--idlc/gen/c_header_gen_base.cc (renamed from idlc/c_gen/c_header_gen_base.cc)4
-rw-r--r--idlc/gen/c_header_gen_base.h (renamed from idlc/c_gen/c_header_gen_base.h)2
-rw-r--r--idlc/gen/c_header_gen_base_cb.h (renamed from idlc/c_gen/c_header_gen_base_cb.h)0
-rw-r--r--idlc/gen/c_proxy_body_gen.cc (renamed from idlc/c_gen/c_proxy_body_gen.cc)4
-rw-r--r--idlc/gen/c_proxy_body_gen.h (renamed from idlc/c_gen/c_proxy_body_gen.h)2
-rw-r--r--idlc/gen/c_proxy_body_gen_cb.h (renamed from idlc/c_gen/c_proxy_body_gen_cb.h)0
-rw-r--r--idlc/gen/c_proxy_header_gen.cc (renamed from idlc/c_gen/c_proxy_header_gen.cc)4
-rw-r--r--idlc/gen/c_proxy_header_gen.h (renamed from idlc/c_gen/c_proxy_header_gen.h)2
-rw-r--r--idlc/gen/c_proxy_header_gen_cb.h (renamed from idlc/c_gen/c_proxy_header_gen_cb.h)0
-rw-r--r--idlc/gen/c_stub_body_gen.cc (renamed from idlc/c_gen/c_stub_body_gen.cc)4
-rw-r--r--idlc/gen/c_stub_body_gen.h (renamed from idlc/c_gen/c_stub_body_gen.h)2
-rw-r--r--idlc/gen/c_stub_body_gen_cb.h (renamed from idlc/c_gen/c_stub_body_gen_cb.h)0
-rw-r--r--idlc/gen/c_stub_header_gen.cc (renamed from idlc/c_gen/c_stub_header_gen.cc)4
-rw-r--r--idlc/gen/c_stub_header_gen.h (renamed from idlc/c_gen/c_stub_header_gen.h)2
-rw-r--r--idlc/gen/c_stub_header_gen_cb.h (renamed from idlc/c_gen/c_stub_header_gen_cb.h)0
-rw-r--r--idlc/gen/cpp_gen_base.cc (renamed from idlc/cpp_gen/cpp_gen_base.cc)4
-rw-r--r--idlc/gen/cpp_gen_base.h (renamed from idlc/cpp_gen/cpp_gen_base.h)6
-rw-r--r--idlc/gen/cpp_gen_base_cb.h (renamed from idlc/cpp_gen/cpp_gen_base_cb.h)0
-rw-r--r--idlc/gen/cpp_proxy_body_gen.cc (renamed from idlc/cpp_gen/cpp_proxy_body_gen.cc)4
-rw-r--r--idlc/gen/cpp_proxy_body_gen.h (renamed from idlc/cpp_gen/cpp_proxy_body_gen.h)2
-rw-r--r--idlc/gen/cpp_proxy_body_gen_cb.h (renamed from idlc/cpp_gen/cpp_proxy_body_gen_cb.h)0
-rw-r--r--idlc/gen/cpp_proxy_header_gen.cc (renamed from idlc/cpp_gen/cpp_proxy_header_gen.cc)4
-rw-r--r--idlc/gen/cpp_proxy_header_gen.h (renamed from idlc/cpp_gen/cpp_proxy_header_gen.h)2
-rw-r--r--idlc/gen/cpp_proxy_header_gen_cb.h (renamed from idlc/cpp_gen/cpp_proxy_header_gen_cb.h)0
-rw-r--r--idlc/gen/cpp_stub_body_gen.cc (renamed from idlc/cpp_gen/cpp_stub_body_gen.cc)4
-rw-r--r--idlc/gen/cpp_stub_body_gen.h (renamed from idlc/cpp_gen/cpp_stub_body_gen.h)2
-rw-r--r--idlc/gen/cpp_stub_body_gen_cb.h (renamed from idlc/cpp_gen/cpp_stub_body_gen_cb.h)0
-rw-r--r--idlc/gen/cpp_stub_header_gen.cc (renamed from idlc/cpp_gen/cpp_stub_header_gen.cc)4
-rw-r--r--idlc/gen/cpp_stub_header_gen.h (renamed from idlc/cpp_gen/cpp_stub_header_gen.h)2
-rw-r--r--idlc/gen/cpp_stub_header_gen_cb.h (renamed from idlc/cpp_gen/cpp_stub_header_gen_cb.h)0
-rw-r--r--idlc/gen/cs_cb_interop.h (renamed from idlc/cs_gen/cs_cb_interop.h)0
-rw-r--r--idlc/gen/cs_cb_rpc_port.h (renamed from idlc/cs_gen/cs_cb_rpc_port.h)0
-rw-r--r--idlc/gen/cs_cb_version.h (renamed from idlc/cs_gen/cs_cb_version.h)0
-rw-r--r--idlc/gen/cs_gen_base.cc (renamed from idlc/cs_gen/cs_gen_base.cc)8
-rw-r--r--idlc/gen/cs_gen_base.h (renamed from idlc/cs_gen/cs_gen_base.h)6
-rw-r--r--idlc/gen/cs_gen_base_cb.h (renamed from idlc/cs_gen/cs_gen_base_cb.h)0
-rw-r--r--idlc/gen/cs_lib_gen.cc (renamed from idlc/cs_gen/cs_lib_gen.cc)6
-rw-r--r--idlc/gen/cs_lib_gen.h (renamed from idlc/cs_gen/cs_lib_gen.h)2
-rw-r--r--idlc/gen/cs_proxy_gen.cc (renamed from idlc/cs_gen/cs_proxy_gen.cc)4
-rw-r--r--idlc/gen/cs_proxy_gen.h (renamed from idlc/cs_gen/cs_proxy_gen.h)2
-rw-r--r--idlc/gen/cs_proxy_gen_cb.h (renamed from idlc/cs_gen/cs_proxy_gen_cb.h)0
-rw-r--r--idlc/gen/cs_stub_gen.cc (renamed from idlc/cs_gen/cs_stub_gen.cc)4
-rw-r--r--idlc/gen/cs_stub_gen.h (renamed from idlc/cs_gen/cs_stub_gen.h)2
-rw-r--r--idlc/gen/cs_stub_gen_cb.h (renamed from idlc/cs_gen/cs_stub_gen_cb.h)0
-rw-r--r--idlc/gen/generator.cc (renamed from idlc/generator.cc)12
-rw-r--r--idlc/gen/generator.h (renamed from idlc/generator.h)6
-rw-r--r--idlc/main.cc24
-rw-r--r--unit_tests/CMakeLists.txt28
-rw-r--r--unit_tests/attribute_unittest.cc2
-rw-r--r--unit_tests/block_unittest.cc2
-rw-r--r--unit_tests/cs_gen/cs_proxy_gen_unittest.cc4
-rw-r--r--unit_tests/cs_gen/cs_stub_gen_unittest.cc4
-rw-r--r--unit_tests/declaration_unittest.cc6
-rw-r--r--unit_tests/document_unittest.cc4
-rw-r--r--unit_tests/element_unittest.cc2
-rw-r--r--unit_tests/generator_unittest.cc8
-rw-r--r--unit_tests/interface_unittest.cc2
-rw-r--r--unit_tests/parser_unittest.cc2
-rw-r--r--unit_tests/structure_unittest.cc2
-rw-r--r--unit_tests/type_unittest.cc2
94 files changed, 469 insertions, 456 deletions
diff --git a/idlc/CMakeLists.txt b/idlc/CMakeLists.txt
index 0507725..1d60f9f 100644
--- a/idlc/CMakeLists.txt
+++ b/idlc/CMakeLists.txt
@@ -25,19 +25,17 @@ SET(CMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS "")
ADD_DEFINITIONS("-DFULLVER=\"${FULLVER}\"")
AUX_SOURCE_DIRECTORY(${CMAKE_CURRENT_SOURCE_DIR} SOURCES)
-AUX_SOURCE_DIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/cs_gen CS_GEN_SOURCES)
-AUX_SOURCE_DIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/c_gen C_GEN_SOURCES)
-AUX_SOURCE_DIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/cpp_gen CPP_GEN_SOURCES)
+AUX_SOURCE_DIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/ast AST_GEN_SOURCES)
+AUX_SOURCE_DIRECTORY(${CMAKE_CURRENT_SOURCE_DIR}/gen GEN_SOURCES)
-BISON_TARGET(TIDLC ${CMAKE_CURRENT_SOURCE_DIR}/tidlc.yy ${CMAKE_CURRENT_SOURCE_DIR}/tidlc_y.cpp)
-FLEX_TARGET(TIDLC ${CMAKE_CURRENT_SOURCE_DIR}/tidlc.ll ${CMAKE_CURRENT_SOURCE_DIR}/tidlc_l.cpp)
+BISON_TARGET(TIDLC ${CMAKE_CURRENT_SOURCE_DIR}/ast/tidlc.yy ${CMAKE_CURRENT_SOURCE_DIR}/ast/tidlc_y.cpp)
+FLEX_TARGET(TIDLC ${CMAKE_CURRENT_SOURCE_DIR}/ast/tidlc.ll ${CMAKE_CURRENT_SOURCE_DIR}/ast/tidlc_l.cpp)
ADD_EXECUTABLE(${PROJECT_NAME}
+ ${AST_GEN_SOURCES}
${BISON_TIDLC_OUTPUTS}
${FLEX_TIDLC_OUTPUTS}
- ${CS_GEN_SOURCES}
- ${C_GEN_SOURCES}
- ${CPP_GEN_SOURCES}
+ ${GEN_SOURCES}
${SOURCES}
)
TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${LIBPKGS_LIBRARIES} ${EXE_STATIC})
diff --git a/idlc/attribute.cc b/idlc/ast/attribute.cc
index 666e071..6fcf86d 100644
--- a/idlc/attribute.cc
+++ b/idlc/ast/attribute.cc
@@ -16,7 +16,7 @@
#include <utility>
-#include "idlc/attribute.h"
+#include "idlc/ast/attribute.h"
namespace tidl {
diff --git a/idlc/attribute.h b/idlc/ast/attribute.h
index 360348e..360348e 100644
--- a/idlc/attribute.h
+++ b/idlc/ast/attribute.h
diff --git a/idlc/block.cc b/idlc/ast/block.cc
index 2a3ee86..3630155 100644
--- a/idlc/block.cc
+++ b/idlc/ast/block.cc
@@ -16,8 +16,8 @@
#include <utility>
-#include "idlc/type.h"
-#include "idlc/block.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/block.h"
namespace tidl {
diff --git a/idlc/block.h b/idlc/ast/block.h
index bbdd026..ea2e19d 100644
--- a/idlc/block.h
+++ b/idlc/ast/block.h
@@ -20,7 +20,7 @@
#include <string>
#include <memory>
-#include "idlc/declaration.h"
+#include "idlc/ast/declaration.h"
namespace tidl {
diff --git a/idlc/declaration.cc b/idlc/ast/declaration.cc
index 3c3c650..400225a 100644
--- a/idlc/declaration.cc
+++ b/idlc/ast/declaration.cc
@@ -16,9 +16,9 @@
#include <utility>
-#include "idlc/declaration.h"
-#include "idlc/type.h"
-#include "idlc/parameter.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
namespace tidl {
diff --git a/idlc/declaration.h b/idlc/ast/declaration.h
index 9f9e17e..13f81dd 100644
--- a/idlc/declaration.h
+++ b/idlc/ast/declaration.h
@@ -21,8 +21,8 @@
#include <list>
#include <memory>
-#include "idlc/type.h"
-#include "idlc/parameter.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
namespace tidl {
diff --git a/idlc/document.cc b/idlc/ast/document.cc
index 07b2bfa..d59e1bb 100644
--- a/idlc/document.cc
+++ b/idlc/ast/document.cc
@@ -14,8 +14,8 @@
* limitations under the License.
*/
-#include "idlc/document.h"
-#include "idlc/block.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/block.h"
namespace tidl {
diff --git a/idlc/document.h b/idlc/ast/document.h
index fda59bf..2c8a3d6 100644
--- a/idlc/document.h
+++ b/idlc/ast/document.h
@@ -20,7 +20,7 @@
#include <list>
#include <memory>
-#include "idlc/interface.h"
+#include "idlc/ast/interface.h"
namespace tidl {
diff --git a/idlc/element.cc b/idlc/ast/element.cc
index 092398c..1594a2a 100644
--- a/idlc/element.cc
+++ b/idlc/ast/element.cc
@@ -16,8 +16,8 @@
#include <utility>
-#include "idlc/element.h"
-#include "idlc/type.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/type.h"
namespace tidl {
diff --git a/idlc/element.h b/idlc/ast/element.h
index 76641a2..ca1b56c 100644
--- a/idlc/element.h
+++ b/idlc/ast/element.h
@@ -21,8 +21,8 @@
#include <list>
#include <memory>
-#include "idlc/type.h"
-#include "idlc/parameter.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
namespace tidl {
diff --git a/idlc/interface.cc b/idlc/ast/interface.cc
index 6a4b3a4..40587a2 100644
--- a/idlc/interface.cc
+++ b/idlc/ast/interface.cc
@@ -16,10 +16,10 @@
#include <utility>
-#include "idlc/declaration.h"
-#include "idlc/attribute.h"
-#include "idlc/interface.h"
-#include "idlc/block.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/attribute.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/block.h"
namespace tidl {
diff --git a/idlc/interface.h b/idlc/ast/interface.h
index b110872..d7463f7 100644
--- a/idlc/interface.h
+++ b/idlc/ast/interface.h
@@ -20,9 +20,9 @@
#include <string>
#include <memory>
-#include "idlc/block.h"
-#include "idlc/declaration.h"
-#include "idlc/attribute.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/attribute.h"
namespace tidl {
diff --git a/idlc/location.hh b/idlc/ast/location.hh
index dffe666..b7c1b5f 100644
--- a/idlc/location.hh
+++ b/idlc/ast/location.hh
@@ -31,18 +31,18 @@
// version 2.2 of Bison.
/**
- ** \file ./idlc/location.hh
+ ** \file /home/gogo/work/next/tidl/idlc/ast/location.hh
** Define the yy::location class.
*/
-#ifndef YY_YY_IDLC_LOCATION_HH_INCLUDED
-# define YY_YY_IDLC_LOCATION_HH_INCLUDED
+#ifndef YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_LOCATION_HH_INCLUDED
+# define YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_LOCATION_HH_INCLUDED
# include "position.hh"
namespace yy {
-#line 46 "./idlc/location.hh" // location.cc:291
+#line 46 "/home/gogo/work/next/tidl/idlc/ast/location.hh" // location.cc:291
/// Abstract a location.
class location
{
@@ -159,5 +159,5 @@ namespace yy {
} // yy
-#line 163 "./idlc/location.hh" // location.cc:291
-#endif // !YY_YY_IDLC_LOCATION_HH_INCLUDED
+#line 163 "/home/gogo/work/next/tidl/idlc/ast/location.hh" // location.cc:291
+#endif // !YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_LOCATION_HH_INCLUDED
diff --git a/idlc/parameter.cc b/idlc/ast/parameter.cc
index 9634626..31633ef 100644
--- a/idlc/parameter.cc
+++ b/idlc/ast/parameter.cc
@@ -16,8 +16,8 @@
#include <utility>
-#include "idlc/parameter.h"
-#include "idlc/type.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/type.h"
namespace tidl {
diff --git a/idlc/parameter.h b/idlc/ast/parameter.h
index c4feeaf..830d397 100644
--- a/idlc/parameter.h
+++ b/idlc/ast/parameter.h
@@ -21,7 +21,7 @@
#include <list>
#include <memory>
-#include "idlc/type.h"
+#include "idlc/ast/type.h"
namespace tidl {
diff --git a/idlc/parser.cc b/idlc/ast/parser.cc
index 706c461..7635efb 100644
--- a/idlc/parser.cc
+++ b/idlc/ast/parser.cc
@@ -17,14 +17,14 @@
#include <fstream>
#include <string>
-#include "idlc/parser.h"
-#include "idlc/document.h"
-#include "idlc/declaration.h"
-#include "idlc/parameter.h"
-#include "idlc/type.h"
-#include "idlc/element.h"
-#include "idlc/structure.h"
-#include "idlc/tidlc_y.hpp"
+#include "idlc/ast/parser.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/tidlc_y.hpp"
struct yy_buffer_state;
yy_buffer_state* yy_scan_buffer(char*, size_t, void*);
diff --git a/idlc/parser.h b/idlc/ast/parser.h
index e90ff8c..6981c6e 100644
--- a/idlc/parser.h
+++ b/idlc/ast/parser.h
@@ -21,7 +21,7 @@
#include <string>
#include <list>
-#include "idlc/document.h"
+#include "idlc/ast/document.h"
namespace tidl {
diff --git a/idlc/position.hh b/idlc/ast/position.hh
index 2154d82..b980804 100644
--- a/idlc/position.hh
+++ b/idlc/ast/position.hh
@@ -31,12 +31,12 @@
// version 2.2 of Bison.
/**
- ** \file ./idlc/position.hh
+ ** \file /home/gogo/work/next/tidl/idlc/ast/position.hh
** Define the yy::position class.
*/
-#ifndef YY_YY_IDLC_POSITION_HH_INCLUDED
-# define YY_YY_IDLC_POSITION_HH_INCLUDED
+#ifndef YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_POSITION_HH_INCLUDED
+# define YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_POSITION_HH_INCLUDED
# include <algorithm> // std::max
# include <iostream>
@@ -52,7 +52,7 @@
namespace yy {
-#line 56 "./idlc/position.hh" // location.cc:291
+#line 56 "/home/gogo/work/next/tidl/idlc/ast/position.hh" // location.cc:291
/// Abstract a position.
class position
{
@@ -165,5 +165,5 @@ namespace yy {
} // yy
-#line 169 "./idlc/position.hh" // location.cc:291
-#endif // !YY_YY_IDLC_POSITION_HH_INCLUDED
+#line 169 "/home/gogo/work/next/tidl/idlc/ast/position.hh" // location.cc:291
+#endif // !YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_POSITION_HH_INCLUDED
diff --git a/idlc/structure.cc b/idlc/ast/structure.cc
index b3d7777..5e7eae6 100644
--- a/idlc/structure.cc
+++ b/idlc/ast/structure.cc
@@ -16,9 +16,9 @@
#include <utility>
-#include "idlc/element.h"
-#include "idlc/structure.h"
-#include "idlc/block.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/block.h"
namespace tidl {
diff --git a/idlc/structure.h b/idlc/ast/structure.h
index 8ed36e9..f9b93b8 100644
--- a/idlc/structure.h
+++ b/idlc/ast/structure.h
@@ -20,8 +20,8 @@
#include <string>
#include <memory>
-#include "idlc/block.h"
-#include "idlc/element.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/element.h"
namespace tidl {
diff --git a/idlc/tidlc.ll b/idlc/ast/tidlc.ll
index a81e5af..226315d 100644
--- a/idlc/tidlc.ll
+++ b/idlc/ast/tidlc.ll
@@ -2,17 +2,17 @@
#include <stdio.h>
#include <string>
-#include "idlc/parser.h"
-#include "idlc/document.h"
-#include "idlc/declaration.h"
-#include "idlc/type.h"
-#include "idlc/parameter.h"
-#include "idlc/interface.h"
-#include "idlc/element.h"
-#include "idlc/structure.h"
-#include "idlc/block.h"
-#include "idlc/attribute.h"
-#include "idlc/tidlc_y.hpp"
+#include "idlc/ast/parser.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/attribute.h"
+#include "idlc/ast/tidlc_y.hpp"
#define YY_USER_ACTION yylloc->columns(yyleng);
%}
diff --git a/idlc/tidlc.yy b/idlc/ast/tidlc.yy
index b3cc1d6..557d5ec 100644
--- a/idlc/tidlc.yy
+++ b/idlc/ast/tidlc.yy
@@ -3,17 +3,17 @@
#include <stdlib.h>
#include <string.h>
-#include "idlc/parser.h"
-#include "idlc/document.h"
-#include "idlc/declaration.h"
-#include "idlc/type.h"
-#include "idlc/parameter.h"
-#include "idlc/interface.h"
-#include "idlc/element.h"
-#include "idlc/structure.h"
-#include "idlc/block.h"
-#include "idlc/attribute.h"
-#include "idlc/tidlc_y.hpp"
+#include "idlc/ast/parser.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/attribute.h"
+#include "idlc/ast/tidlc_y.hpp"
int yylex(yy::parser::semantic_type *, yy::parser::location_type *, void *);
diff --git a/idlc/tidlc_l.cpp b/idlc/ast/tidlc_l.cpp
index 888d35b..f8c6386 100644
--- a/idlc/tidlc_l.cpp
+++ b/idlc/ast/tidlc_l.cpp
@@ -1,6 +1,6 @@
-#line 2 "./idlc/tidlc_l.cpp"
+#line 2 "/home/gogo/work/next/tidl/idlc/ast/tidlc_l.cpp"
-#line 4 "./idlc/tidlc_l.cpp"
+#line 4 "/home/gogo/work/next/tidl/idlc/ast/tidlc_l.cpp"
#define YY_INT_ALIGNED short int
@@ -549,26 +549,26 @@ static yyconst flex_int32_t yy_rule_can_match_eol[46] =
#define yymore() yymore_used_but_not_detected
#define YY_MORE_ADJ 0
#define YY_RESTORE_YY_MORE_OFFSET
-#line 1 "./idlc/tidlc.ll"
-#line 2 "./idlc/tidlc.ll"
+#line 1 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
+#line 2 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
#include <stdio.h>
#include <string>
-#include "idlc/parser.h"
-#include "idlc/document.h"
-#include "idlc/declaration.h"
-#include "idlc/type.h"
-#include "idlc/parameter.h"
-#include "idlc/interface.h"
-#include "idlc/element.h"
-#include "idlc/structure.h"
-#include "idlc/block.h"
-#include "idlc/attribute.h"
-#include "idlc/tidlc_y.hpp"
+#include "idlc/ast/parser.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/attribute.h"
+#include "idlc/ast/tidlc_y.hpp"
#define YY_USER_ACTION yylloc->columns(yyleng);
-#line 572 "./idlc/tidlc_l.cpp"
+#line 572 "/home/gogo/work/next/tidl/idlc/ast/tidlc_l.cpp"
#define INITIAL 0
#define COMMENT 1
@@ -851,14 +851,14 @@ YY_DECL
}
{
-#line 28 "./idlc/tidlc.ll"
+#line 28 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
std::string comments;
std::string values;
-#line 862 "./idlc/tidlc_l.cpp"
+#line 862 "/home/gogo/work/next/tidl/idlc/ast/tidlc_l.cpp"
while ( 1 ) /* loops until end-of-file is reached */
{
@@ -929,55 +929,55 @@ do_action: /* This label is used only to access EOF actions. */
case 1:
YY_RULE_SETUP
-#line 34 "./idlc/tidlc.ll"
+#line 34 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; BEGIN(COMMENT); }
YY_BREAK
case 2:
YY_RULE_SETUP
-#line 35 "./idlc/tidlc.ll"
+#line 35 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; yylloc->step(); BEGIN(INITIAL); }
YY_BREAK
case 3:
YY_RULE_SETUP
-#line 36 "./idlc/tidlc.ll"
+#line 36 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; comments += "\n"; BEGIN(INITIAL); }
YY_BREAK
case 4:
/* rule 4 can match eol */
YY_RULE_SETUP
-#line 37 "./idlc/tidlc.ll"
+#line 37 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; yylloc->step(); BEGIN(INITIAL); }
YY_BREAK
case 5:
/* rule 5 can match eol */
YY_RULE_SETUP
-#line 38 "./idlc/tidlc.ll"
+#line 38 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; yylloc->lines(yyleng); }
YY_BREAK
case 6:
/* rule 6 can match eol */
YY_RULE_SETUP
-#line 39 "./idlc/tidlc.ll"
+#line 39 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; yylloc->step(); }
YY_BREAK
case YY_STATE_EOF(COMMENT):
-#line 40 "./idlc/tidlc.ll"
+#line 40 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return 0; }
YY_BREAK
case 7:
/* rule 7 can match eol */
YY_RULE_SETUP
-#line 42 "./idlc/tidlc.ll"
+#line 42 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ comments += yytext; yylloc->step(); }
YY_BREAK
case 8:
YY_RULE_SETUP
-#line 44 "./idlc/tidlc.ll"
+#line 44 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ BEGIN(VALUE); }
YY_BREAK
case 9:
YY_RULE_SETUP
-#line 45 "./idlc/tidlc.ll"
+#line 45 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
BEGIN(INITIAL);
yylval->token = new tidl::Token(values, comments);
@@ -987,54 +987,54 @@ YY_RULE_SETUP
case 10:
/* rule 10 can match eol */
YY_RULE_SETUP
-#line 50 "./idlc/tidlc.ll"
+#line 50 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ values += yytext; yylloc->step(); }
YY_BREAK
case 11:
/* rule 11 can match eol */
YY_RULE_SETUP
-#line 52 "./idlc/tidlc.ll"
+#line 52 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ yylloc->lines(yyleng); yylloc->step(); }
YY_BREAK
case 12:
/* rule 12 can match eol */
YY_RULE_SETUP
-#line 54 "./idlc/tidlc.ll"
+#line 54 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
; // ignore all whitespace
YY_BREAK
case 13:
YY_RULE_SETUP
-#line 55 "./idlc/tidlc.ll"
+#line 55 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_COMMA; }
YY_BREAK
case 14:
YY_RULE_SETUP
-#line 56 "./idlc/tidlc.ll"
+#line 56 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_BRACE_OPEN; }
YY_BREAK
case 15:
YY_RULE_SETUP
-#line 57 "./idlc/tidlc.ll"
+#line 57 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_BRACE_CLOSE; }
YY_BREAK
case 16:
YY_RULE_SETUP
-#line 58 "./idlc/tidlc.ll"
+#line 58 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_LEFT; }
YY_BREAK
case 17:
YY_RULE_SETUP
-#line 59 "./idlc/tidlc.ll"
+#line 59 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_RIGHT; }
YY_BREAK
case 18:
YY_RULE_SETUP
-#line 60 "./idlc/tidlc.ll"
+#line 60 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_SEMICOLON; }
YY_BREAK
case 19:
YY_RULE_SETUP
-#line 61 "./idlc/tidlc.ll"
+#line 61 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_VOID;
@@ -1042,7 +1042,7 @@ YY_RULE_SETUP
YY_BREAK
case 20:
YY_RULE_SETUP
-#line 65 "./idlc/tidlc.ll"
+#line 65 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_CHAR;
@@ -1050,7 +1050,7 @@ YY_RULE_SETUP
YY_BREAK
case 21:
YY_RULE_SETUP
-#line 69 "./idlc/tidlc.ll"
+#line 69 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_SHORT;
@@ -1058,7 +1058,7 @@ YY_RULE_SETUP
YY_BREAK
case 22:
YY_RULE_SETUP
-#line 73 "./idlc/tidlc.ll"
+#line 73 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_INT;
@@ -1066,7 +1066,7 @@ YY_RULE_SETUP
YY_BREAK
case 23:
YY_RULE_SETUP
-#line 77 "./idlc/tidlc.ll"
+#line 77 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_LONG;
@@ -1074,7 +1074,7 @@ YY_RULE_SETUP
YY_BREAK
case 24:
YY_RULE_SETUP
-#line 81 "./idlc/tidlc.ll"
+#line 81 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_FLOAT;
@@ -1082,7 +1082,7 @@ YY_RULE_SETUP
YY_BREAK
case 25:
YY_RULE_SETUP
-#line 85 "./idlc/tidlc.ll"
+#line 85 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_DOUBLE;
@@ -1090,7 +1090,7 @@ YY_RULE_SETUP
YY_BREAK
case 26:
YY_RULE_SETUP
-#line 89 "./idlc/tidlc.ll"
+#line 89 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_BUNDLE;
@@ -1098,7 +1098,7 @@ YY_RULE_SETUP
YY_BREAK
case 27:
YY_RULE_SETUP
-#line 93 "./idlc/tidlc.ll"
+#line 93 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_STRING;
@@ -1106,7 +1106,7 @@ YY_RULE_SETUP
YY_BREAK
case 28:
YY_RULE_SETUP
-#line 97 "./idlc/tidlc.ll"
+#line 97 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_BOOL;
@@ -1114,42 +1114,42 @@ YY_RULE_SETUP
YY_BREAK
case 29:
YY_RULE_SETUP
-#line 101 "./idlc/tidlc.ll"
+#line 101 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_IN; }
YY_BREAK
case 30:
YY_RULE_SETUP
-#line 102 "./idlc/tidlc.ll"
+#line 102 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_OUT; }
YY_BREAK
case 31:
YY_RULE_SETUP
-#line 103 "./idlc/tidlc.ll"
+#line 103 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_REF; }
YY_BREAK
case 32:
YY_RULE_SETUP
-#line 104 "./idlc/tidlc.ll"
+#line 104 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_ASYNC; }
YY_BREAK
case 33:
YY_RULE_SETUP
-#line 105 "./idlc/tidlc.ll"
+#line 105 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_DELEGATE; }
YY_BREAK
case 34:
YY_RULE_SETUP
-#line 106 "./idlc/tidlc.ll"
+#line 106 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_META_OPEN; }
YY_BREAK
case 35:
YY_RULE_SETUP
-#line 107 "./idlc/tidlc.ll"
+#line 107 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_META_CLOSE; }
YY_BREAK
case 36:
YY_RULE_SETUP
-#line 108 "./idlc/tidlc.ll"
+#line 108 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_LIST;
@@ -1157,7 +1157,7 @@ YY_RULE_SETUP
YY_BREAK
case 37:
YY_RULE_SETUP
-#line 112 "./idlc/tidlc.ll"
+#line 112 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_ARRAY;
@@ -1165,7 +1165,7 @@ YY_RULE_SETUP
YY_BREAK
case 38:
YY_RULE_SETUP
-#line 116 "./idlc/tidlc.ll"
+#line 116 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_STRUCTURE;
@@ -1173,7 +1173,7 @@ YY_RULE_SETUP
YY_BREAK
case 39:
YY_RULE_SETUP
-#line 120 "./idlc/tidlc.ll"
+#line 120 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_INTERFACE;
@@ -1181,7 +1181,7 @@ YY_RULE_SETUP
YY_BREAK
case 40:
YY_RULE_SETUP
-#line 124 "./idlc/tidlc.ll"
+#line 124 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_ID;
@@ -1189,7 +1189,7 @@ YY_RULE_SETUP
YY_BREAK
case 41:
YY_RULE_SETUP
-#line 128 "./idlc/tidlc.ll"
+#line 128 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ // Square Bracket
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_SB_OPEN;
@@ -1197,7 +1197,7 @@ YY_RULE_SETUP
YY_BREAK
case 42:
YY_RULE_SETUP
-#line 132 "./idlc/tidlc.ll"
+#line 132 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ // Square Bracket
yylval->token = new tidl::Token(yytext, comments);
return yy::parser::token::T_SB_CLOSE;
@@ -1205,20 +1205,20 @@ YY_RULE_SETUP
YY_BREAK
case 43:
YY_RULE_SETUP
-#line 136 "./idlc/tidlc.ll"
+#line 136 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_EQUAL; }
YY_BREAK
case 44:
YY_RULE_SETUP
-#line 137 "./idlc/tidlc.ll"
+#line 137 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
{ return yy::parser::token::T_UNKNOWN; }
YY_BREAK
case 45:
YY_RULE_SETUP
-#line 139 "./idlc/tidlc.ll"
+#line 139 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
ECHO;
YY_BREAK
-#line 1222 "./idlc/tidlc_l.cpp"
+#line 1222 "/home/gogo/work/next/tidl/idlc/ast/tidlc_l.cpp"
case YY_STATE_EOF(INITIAL):
case YY_STATE_EOF(VALUE):
yyterminate();
@@ -2407,7 +2407,7 @@ void yyfree (void * ptr , yyscan_t yyscanner)
#define YYTABLES_NAME "yytables"
-#line 138 "./idlc/tidlc.ll"
+#line 138 "/home/gogo/work/next/tidl/idlc/ast/tidlc.ll"
diff --git a/idlc/tidlc_y.cpp b/idlc/ast/tidlc_y.cpp
index 5a21a4e..5c9f624 100644
--- a/idlc/tidlc_y.cpp
+++ b/idlc/ast/tidlc_y.cpp
@@ -50,30 +50,30 @@
/* First part of user declarations. */
-#line 1 "./idlc/tidlc.yy" // glr.c:207
+#line 1 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:207
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-#include "idlc/parser.h"
-#include "idlc/document.h"
-#include "idlc/declaration.h"
-#include "idlc/type.h"
-#include "idlc/parameter.h"
-#include "idlc/interface.h"
-#include "idlc/element.h"
-#include "idlc/structure.h"
-#include "idlc/block.h"
-#include "idlc/attribute.h"
-#include "idlc/tidlc_y.hpp"
+#include "idlc/ast/parser.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/element.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/attribute.h"
+#include "idlc/ast/tidlc_y.hpp"
int yylex(yy::parser::semantic_type *, yy::parser::location_type *, void *);
#define lex_scanner ps->Scanner()
-#line 77 "./idlc/tidlc_y.cpp" // glr.c:207
+#line 77 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:207
# ifndef YY_NULLPTR
# if defined __cplusplus && 201103L <= __cplusplus
@@ -105,7 +105,7 @@ static YYLTYPE yyloc_default
;
/* Copy the second part of user declarations. */
-#line 109 "./idlc/tidlc_y.cpp" // glr.c:230
+#line 109 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:230
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
If N is 0, then set CURRENT to the empty location which ends
the previous symbol: RHS[0] (always defined). */
@@ -127,7 +127,7 @@ static YYLTYPE yyloc_default
#define YYRHSLOC(Rhs, K) ((Rhs)[K].yystate.yyloc)
static void yyerror (const yy::parser::location_type *yylocationp, yy::parser& yyparser, tidl::Parser* ps, const char* msg);
-#line 131 "./idlc/tidlc_y.cpp" // glr.c:230
+#line 131 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:230
#include <stdio.h>
#include <stdlib.h>
@@ -297,12 +297,12 @@ static const unsigned char yytranslate[] =
static const unsigned short int yyrline[] =
{
0, 94, 94, 99, 104, 118, 121, 126, 132, 137,
- 143, 150, 154, 163, 169, 174, 178, 182, 188, 192,
- 201, 207, 212, 218, 225, 231, 239, 244, 249, 256,
- 260, 269, 275, 280, 287, 295, 300, 305, 310, 314,
- 318, 322, 326, 332, 337, 346, 352, 355, 358, 363,
- 366, 370, 376, 379, 385, 388, 392, 396, 400, 404,
- 408, 412, 416, 420, 424, 428, 434, 441, 445
+ 143, 150, 156, 167, 173, 178, 182, 186, 192, 198,
+ 209, 215, 220, 226, 233, 239, 247, 252, 257, 264,
+ 270, 281, 287, 292, 299, 307, 312, 317, 322, 326,
+ 330, 334, 338, 344, 350, 361, 367, 370, 373, 378,
+ 381, 385, 391, 394, 400, 403, 407, 411, 415, 419,
+ 423, 427, 431, 435, 439, 443, 449, 456, 460
};
#endif
@@ -1088,25 +1088,25 @@ yyuserAction (yyRuleNum yyn, size_t yyrhslen, yyGLRStackItem* yyvsp,
switch (yyn)
{
case 2:
-#line 94 "./idlc/tidlc.yy" // glr.c:783
+#line 94 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->SetDoc((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.doc));
}
-#line 1096 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1096 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 3:
-#line 99 "./idlc/tidlc.yy" // glr.c:783
+#line 99 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).doc) = new tidl::Document();
if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.blk) != NULL)
((*yyvalp).doc)->AddBlock((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.blk));
}
-#line 1106 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1106 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 4:
-#line 104 "./idlc/tidlc.yy" // glr.c:783
+#line 104 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).doc) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.doc);
@@ -1119,212 +1119,220 @@ yyuserAction (yyRuleNum yyn, size_t yyrhslen, yyGLRStackItem* yyvsp,
}
}
}
-#line 1123 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1123 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 5:
-#line 118 "./idlc/tidlc.yy" // glr.c:783
+#line 118 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).blk) = (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.interf);
}
-#line 1131 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1131 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 6:
-#line 121 "./idlc/tidlc.yy" // glr.c:783
+#line 121 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).blk) = (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.structure);
}
-#line 1139 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1139 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 7:
-#line 126 "./idlc/tidlc.yy" // glr.c:783
+#line 126 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).structure) = new tidl::Structure((((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.elms), (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token)->GetComments(),
(((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yyloc).begin.line);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token);
}
-#line 1150 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1150 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 8:
-#line 132 "./idlc/tidlc.yy" // glr.c:783
+#line 132 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No identifier\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yyloc).begin.line);
((*yyvalp).structure) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token);
}
-#line 1160 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1160 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 9:
-#line 137 "./idlc/tidlc.yy" // glr.c:783
+#line 137 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"Please check it before an open brace.\"",
(((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yyloc).begin.line);
((*yyvalp).structure) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
}
-#line 1171 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1171 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 10:
-#line 143 "./idlc/tidlc.yy" // glr.c:783
+#line 143 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in structure declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).structure) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.token);
}
-#line 1181 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1181 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 11:
-#line 150 "./idlc/tidlc.yy" // glr.c:783
+#line 150 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
- ((*yyvalp).elms) = new tidl::Elements();
- ((*yyvalp).elms)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm));
+ ((*yyvalp).elms) = new (std::nothrow) tidl::Elements();
+ if (((*yyvalp).elms) != nullptr) {
+ ((*yyvalp).elms)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm));
+ }
}
-#line 1190 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1192 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 12:
-#line 154 "./idlc/tidlc.yy" // glr.c:783
+#line 156 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).elms) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.elms);
- if (((*yyvalp).elms)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm))) {
- ps->ReportError("syntax error. \"Already Exists\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm)->GetLine());
- delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm);
- } else {
- ((*yyvalp).elms)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm));
+ if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm) != nullptr) {
+ if (((*yyvalp).elms)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm))) {
+ ps->ReportError("syntax error. \"Already Exists\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm)->GetLine());
+ delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm);
+ } else {
+ ((*yyvalp).elms)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.elm));
+ }
}
}
-#line 1204 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1208 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 13:
-#line 163 "./idlc/tidlc.yy" // glr.c:783
+#line 167 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in elements declarations.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yyloc).begin.line);
((*yyvalp).elms) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.elms);
}
-#line 1213 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1217 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 14:
-#line 169 "./idlc/tidlc.yy" // glr.c:783
+#line 173 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).elm) = new tidl::Element((((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.b_type), (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.b_type)->GetComments(),
(((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yyloc).begin.line);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.token);
}
-#line 1223 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1227 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 15:
-#line 174 "./idlc/tidlc.yy" // glr.c:783
+#line 178 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No identifier\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yyloc).begin.line);
((*yyvalp).elm) = NULL;
}
-#line 1232 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1236 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 16:
-#line 178 "./idlc/tidlc.yy" // glr.c:783
+#line 182 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in element declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).elm) = NULL;
}
-#line 1241 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1245 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 17:
-#line 182 "./idlc/tidlc.yy" // glr.c:783
+#line 186 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in element declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yyloc).begin.line);
((*yyvalp).elm) = NULL;
}
-#line 1250 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1254 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 18:
-#line 188 "./idlc/tidlc.yy" // glr.c:783
+#line 192 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
- ((*yyvalp).attrs) = new tidl::Attributes();
- ((*yyvalp).attrs)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr));
+ ((*yyvalp).attrs) = new (std::nothrow) tidl::Attributes();
+ if (((*yyvalp).attrs) != nullptr) {
+ ((*yyvalp).attrs)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr));
+ }
}
-#line 1259 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1265 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 19:
-#line 192 "./idlc/tidlc.yy" // glr.c:783
+#line 198 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).attrs) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.attrs);
- if (((*yyvalp).attrs)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr))) {
- ps->ReportError("syntax error. \"Already Exist\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr)->GetLine());
- delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr);
- } else {
- ((*yyvalp).attrs)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr));
+ if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr) != nullptr) {
+ if (((*yyvalp).attrs)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr))) {
+ ps->ReportError("syntax error. \"Already Exist\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr)->GetLine());
+ delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr);
+ } else {
+ ((*yyvalp).attrs)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.attr));
+ }
}
}
-#line 1273 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1281 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 20:
-#line 201 "./idlc/tidlc.yy" // glr.c:783
+#line 209 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in attributes", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yyloc).begin.line);
((*yyvalp).attrs) = new tidl::Attributes();
}
-#line 1282 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1290 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 21:
-#line 207 "./idlc/tidlc.yy" // glr.c:783
+#line 215 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).attr) = new tidl::Attribute((((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yyloc).begin.line);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1292 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1300 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 22:
-#line 212 "./idlc/tidlc.yy" // glr.c:783
+#line 220 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in attribute declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).attr) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1303 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1311 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 23:
-#line 218 "./idlc/tidlc.yy" // glr.c:783
+#line 226 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in attribute declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yyloc).begin.line);
((*yyvalp).attr) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.token);
}
-#line 1313 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1321 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 24:
-#line 225 "./idlc/tidlc.yy" // glr.c:783
+#line 233 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).interf) = new tidl::Interface((((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.decls), (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token)->GetComments(),
new tidl::Attributes(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yyloc).begin.line);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token);
}
-#line 1324 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1332 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 25:
-#line 231 "./idlc/tidlc.yy" // glr.c:783
+#line 239 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).interf) = new tidl::Interface((((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.decls), (((yyGLRStackItem const *)yyvsp)[YYFILL (-7)].yystate.yysemantics.yysval.token)->GetComments(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval.attrs),
(((yyGLRStackItem const *)yyvsp)[YYFILL (-7)].yystate.yyloc).begin.line);
@@ -1333,83 +1341,87 @@ yyuserAction (yyRuleNum yyn, size_t yyrhslen, yyGLRStackItem* yyvsp,
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token);
}
-#line 1337 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1345 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 26:
-#line 239 "./idlc/tidlc.yy" // glr.c:783
+#line 247 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No identifier\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yyloc).begin.line);
((*yyvalp).interf) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token);
}
-#line 1347 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1355 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 27:
-#line 244 "./idlc/tidlc.yy" // glr.c:783
+#line 252 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in interface declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yyloc).begin.line);
((*yyvalp).interf) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
}
-#line 1357 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1365 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 28:
-#line 249 "./idlc/tidlc.yy" // glr.c:783
+#line 257 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in interface declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).interf) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.token);
}
-#line 1367 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1375 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 29:
-#line 256 "./idlc/tidlc.yy" // glr.c:783
+#line 264 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
- ((*yyvalp).decls) = new tidl::Declarations();
- ((*yyvalp).decls)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl));
+ ((*yyvalp).decls) = new (std::nothrow) tidl::Declarations();
+ if (((*yyvalp).decls) != nullptr) {
+ ((*yyvalp).decls)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl));
+ }
}
-#line 1376 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1386 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 30:
-#line 260 "./idlc/tidlc.yy" // glr.c:783
+#line 270 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).decls) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.decls);
- if (((*yyvalp).decls)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl))) {
- ps->ReportError("syntax error. \"Already Exists\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl)->GetLine());
- delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl);
- } else {
- ((*yyvalp).decls)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl));
+ if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl) != nullptr) {
+ if (((*yyvalp).decls)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl))) {
+ ps->ReportError("syntax error. \"Already Exists\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl)->GetLine());
+ delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl);
+ } else {
+ ((*yyvalp).decls)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.decl));
+ }
}
}
-#line 1390 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1402 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 31:
-#line 269 "./idlc/tidlc.yy" // glr.c:783
+#line 281 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in methods declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).decls) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.decls);
}
-#line 1399 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1411 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 32:
-#line 275 "./idlc/tidlc.yy" // glr.c:783
+#line 287 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).decl) = new tidl::Declaration((((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.b_type), (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.params), (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.b_type)->GetComments(),
(((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yyloc).begin.line, tidl::Declaration::MethodType::SYNC);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
}
-#line 1409 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1421 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 33:
-#line 280 "./idlc/tidlc.yy" // glr.c:783
+#line 292 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).decl) = new tidl::Declaration((((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.token)->ToString(),
new tidl::BaseType("void", (((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval.token)->GetComments()), (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.params),
@@ -1417,11 +1429,11 @@ yyuserAction (yyRuleNum yyn, size_t yyrhslen, yyGLRStackItem* yyvsp,
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.token);
}
-#line 1421 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1433 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 34:
-#line 287 "./idlc/tidlc.yy" // glr.c:783
+#line 299 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).decl) = new tidl::Declaration((((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.token)->ToString(),
new tidl::BaseType("void", (((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval.token)->GetComments()), (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.params),
@@ -1430,321 +1442,324 @@ yyuserAction (yyRuleNum yyn, size_t yyrhslen, yyGLRStackItem* yyvsp,
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-6)].yystate.yysemantics.yysval.token);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.token);
}
-#line 1434 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1446 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 35:
-#line 295 "./idlc/tidlc.yy" // glr.c:783
+#line 307 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in method declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.token);
}
-#line 1444 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1456 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 36:
-#line 300 "./idlc/tidlc.yy" // glr.c:783
+#line 312 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in method declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-5)].yystate.yysemantics.yysval.token);
}
-#line 1454 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1466 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 37:
-#line 305 "./idlc/tidlc.yy" // glr.c:783
+#line 317 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No async\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yysemantics.yysval.token);
}
-#line 1464 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1476 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 38:
-#line 310 "./idlc/tidlc.yy" // glr.c:783
+#line 322 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No identifier\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
}
-#line 1473 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1485 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 39:
-#line 314 "./idlc/tidlc.yy" // glr.c:783
+#line 326 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No identifier\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
}
-#line 1482 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1494 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 40:
-#line 318 "./idlc/tidlc.yy" // glr.c:783
+#line 330 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error. \"No identifier\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (-4)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
}
-#line 1491 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1503 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 41:
-#line 322 "./idlc/tidlc.yy" // glr.c:783
+#line 334 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in method declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
}
-#line 1500 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1512 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 42:
-#line 326 "./idlc/tidlc.yy" // glr.c:783
+#line 338 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in method declaration.", (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
((*yyvalp).decl) = NULL;
}
-#line 1509 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1521 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 43:
-#line 332 "./idlc/tidlc.yy" // glr.c:783
+#line 344 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).params) = new tidl::Parameters();
- if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param) != nullptr)
+ if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param) != nullptr) {
((*yyvalp).params)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param));
+ }
}
-#line 1519 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1532 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 44:
-#line 337 "./idlc/tidlc.yy" // glr.c:783
+#line 350 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).params) = (((yyGLRStackItem const *)yyvsp)[YYFILL (-2)].yystate.yysemantics.yysval.params);
- if (((*yyvalp).params)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param))) {
- ps->ReportError("syntax error. \"Already Exists\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param)->GetLine());
- delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param);
- } else {
- ((*yyvalp).params)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param));
+ if ((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param) != nullptr) {
+ if (((*yyvalp).params)->Exist((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param))) {
+ ps->ReportError("syntax error. \"Already Exists\".", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param)->GetLine());
+ delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param);
+ } else {
+ ((*yyvalp).params)->Add((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.param));
+ }
}
}
-#line 1533 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1548 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 45:
-#line 346 "./idlc/tidlc.yy" // glr.c:783
+#line 361 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
ps->ReportError("syntax error in parameter list", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yyloc).begin.line);
((*yyvalp).params) = new tidl::Parameters();
}
-#line 1542 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1557 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 46:
-#line 352 "./idlc/tidlc.yy" // glr.c:783
+#line 367 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).direction) = new tidl::Token("in", "");
}
-#line 1550 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1565 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 47:
-#line 355 "./idlc/tidlc.yy" // glr.c:783
+#line 370 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).direction) = new tidl::Token("out", "");
}
-#line 1558 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1573 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 48:
-#line 358 "./idlc/tidlc.yy" // glr.c:783
+#line 373 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).direction) = new tidl::Token("ref", "");
}
-#line 1566 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1581 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 49:
-#line 363 "./idlc/tidlc.yy" // glr.c:783
+#line 378 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).param) = nullptr;
}
-#line 1574 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1589 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 50:
-#line 366 "./idlc/tidlc.yy" // glr.c:783
+#line 381 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).param) = nullptr;
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1583 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1598 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 51:
-#line 370 "./idlc/tidlc.yy" // glr.c:783
+#line 385 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).param) = new tidl::Parameter((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.p_type), (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yyloc).begin.line);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1592 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1607 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 52:
-#line 376 "./idlc/tidlc.yy" // glr.c:783
+#line 391 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).p_type) = new tidl::ParameterType((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.b_type));
}
-#line 1600 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1615 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 53:
-#line 379 "./idlc/tidlc.yy" // glr.c:783
+#line 394 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).p_type) = new tidl::ParameterType((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.b_type), (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.direction)->ToString());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.direction);
}
-#line 1609 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1624 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 54:
-#line 385 "./idlc/tidlc.yy" // glr.c:783
+#line 400 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.b_type);
}
-#line 1617 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1632 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 55:
-#line 388 "./idlc/tidlc.yy" // glr.c:783
+#line 403 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("void", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1626 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1641 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 56:
-#line 392 "./idlc/tidlc.yy" // glr.c:783
+#line 407 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("char", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1635 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1650 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 57:
-#line 396 "./idlc/tidlc.yy" // glr.c:783
+#line 411 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("short", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1644 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1659 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 58:
-#line 400 "./idlc/tidlc.yy" // glr.c:783
+#line 415 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("int", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1653 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1668 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 59:
-#line 404 "./idlc/tidlc.yy" // glr.c:783
+#line 419 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("long", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1662 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1677 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 60:
-#line 408 "./idlc/tidlc.yy" // glr.c:783
+#line 423 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("float", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1671 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1686 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 61:
-#line 412 "./idlc/tidlc.yy" // glr.c:783
+#line 427 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("double", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1680 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1695 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 62:
-#line 416 "./idlc/tidlc.yy" // glr.c:783
+#line 431 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("bundle", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1689 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1704 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 63:
-#line 420 "./idlc/tidlc.yy" // glr.c:783
+#line 435 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("string", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1698 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1713 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 64:
-#line 424 "./idlc/tidlc.yy" // glr.c:783
+#line 439 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType("bool", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1707 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1722 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 65:
-#line 428 "./idlc/tidlc.yy" // glr.c:783
+#line 443 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType((((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments(), true);
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1716 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1731 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 66:
-#line 434 "./idlc/tidlc.yy" // glr.c:783
+#line 449 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).b_type) = new tidl::BaseType((((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token)->ToString(), (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token)->GetComments());
((*yyvalp).b_type)->SetMetaType((((yyGLRStackItem const *)yyvsp)[YYFILL (-1)].yystate.yysemantics.yysval.b_type));
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (-3)].yystate.yysemantics.yysval.token);
}
-#line 1726 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1741 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 67:
-#line 441 "./idlc/tidlc.yy" // glr.c:783
+#line 456 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).token) = new tidl::Token("list", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1735 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1750 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
case 68:
-#line 445 "./idlc/tidlc.yy" // glr.c:783
+#line 460 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:783
{
((*yyvalp).token) = new tidl::Token("array", (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token)->GetComments());
delete (((yyGLRStackItem const *)yyvsp)[YYFILL (0)].yystate.yysemantics.yysval.token);
}
-#line 1744 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1759 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
break;
-#line 1748 "./idlc/tidlc_y.cpp" // glr.c:783
+#line 1763 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:783
default: break;
}
@@ -3219,7 +3234,7 @@ yyparse (yy::parser& yyparser, tidl::Parser* ps)
/* User initialization code. */
yylloc.initialize ();
-#line 3223 "./idlc/tidlc_y.cpp" // glr.c:2237
+#line 3238 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:2237
if (! yyinitGLRStack (yystackp, YYINITDEPTH))
goto yyexhaustedlab;
@@ -3520,7 +3535,7 @@ yypdumpstack (yyGLRStack* yystackp)
-#line 451 "./idlc/tidlc.yy" // glr.c:2551
+#line 466 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.c:2551
#include <ctype.h>
@@ -3532,7 +3547,7 @@ void yy::parser::error(const yy::parser::location_type& l,
}
-#line 3536 "./idlc/tidlc_y.cpp" // glr.c:2551
+#line 3551 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:2551
/*------------------.
| Report an error. |
@@ -3549,7 +3564,7 @@ yyerror (const yy::parser::location_type *yylocationp, yy::parser& yyparser, tid
namespace yy {
-#line 3553 "./idlc/tidlc_y.cpp" // glr.c:2551
+#line 3568 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:2551
/// Build a parser object.
parser::parser (tidl::Parser* ps_yyarg)
:
@@ -3630,4 +3645,4 @@ namespace yy {
#endif
} // yy
-#line 3634 "./idlc/tidlc_y.cpp" // glr.c:2551
+#line 3649 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.cpp" // glr.c:2551
diff --git a/idlc/tidlc_y.hpp b/idlc/ast/tidlc_y.hpp
index 6dc7a6f..fa8c197 100644
--- a/idlc/tidlc_y.hpp
+++ b/idlc/ast/tidlc_y.hpp
@@ -32,8 +32,8 @@
// C++ GLR parser skeleton written by Akim Demaille.
-#ifndef YY_YY_IDLC_TIDLC_Y_HPP_INCLUDED
-# define YY_YY_IDLC_TIDLC_Y_HPP_INCLUDED
+#ifndef YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_TIDLC_Y_HPP_INCLUDED
+# define YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_TIDLC_Y_HPP_INCLUDED
#include <stdexcept>
@@ -48,7 +48,7 @@
namespace yy {
-#line 52 "./idlc/tidlc_y.hpp" // glr.cc:329
+#line 52 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.hpp" // glr.cc:329
/// A Bison parser.
@@ -59,7 +59,7 @@ namespace yy {
/// Symbol semantic values.
union semantic_type
{
- #line 37 "./idlc/tidlc.yy" // glr.cc:329
+ #line 37 "/home/gogo/work/next/tidl/idlc/ast/tidlc.yy" // glr.cc:329
tidl::Document* doc;
tidl::Interface* interf;
@@ -78,7 +78,7 @@ namespace yy {
tidl::Attribute* attr;
tidl::Attributes* attrs;
-#line 82 "./idlc/tidlc_y.hpp" // glr.cc:329
+#line 82 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.hpp" // glr.cc:329
};
#else
typedef YYSTYPE semantic_type;
@@ -286,7 +286,7 @@ namespace yy {
} // yy
-#line 290 "./idlc/tidlc_y.hpp" // glr.cc:329
+#line 290 "/home/gogo/work/next/tidl/idlc/ast/tidlc_y.hpp" // glr.cc:329
-#endif // !YY_YY_IDLC_TIDLC_Y_HPP_INCLUDED
+#endif // !YY_YY_HOME_GOGO_WORK_NEXT_TIDL_IDLC_AST_TIDLC_Y_HPP_INCLUDED
diff --git a/idlc/type.cc b/idlc/ast/type.cc
index e070533..09ad70e 100644
--- a/idlc/type.cc
+++ b/idlc/ast/type.cc
@@ -17,7 +17,7 @@
#include <iostream>
#include <utility>
-#include "idlc/type.h"
+#include "idlc/ast/type.h"
namespace tidl {
diff --git a/idlc/type.h b/idlc/ast/type.h
index e3cf288..e3cf288 100644
--- a/idlc/type.h
+++ b/idlc/ast/type.h
diff --git a/idlc/c_gen/c_body_gen_base.cc b/idlc/gen/c_body_gen_base.cc
index 8f8cde2..63354b0 100644
--- a/idlc/c_gen/c_body_gen_base.cc
+++ b/idlc/gen/c_body_gen_base.cc
@@ -16,10 +16,10 @@
#include <vector>
-#include "idlc/c_gen/c_body_gen_base.h"
+#include "idlc/gen/c_body_gen_base.h"
namespace {
-#include "idlc/c_gen/c_body_gen_base_cb.h"
+#include "idlc/gen/c_body_gen_base_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_body_gen_base.h b/idlc/gen/c_body_gen_base.h
index 32af40a..7de8246 100644
--- a/idlc/c_gen/c_body_gen_base.h
+++ b/idlc/gen/c_body_gen_base.h
@@ -21,7 +21,7 @@
#include <string>
#include <map>
-#include "idlc/c_gen/c_gen_base.h"
+#include "idlc/gen/c_gen_base.h"
namespace tidl {
diff --git a/idlc/c_gen/c_body_gen_base_cb.h b/idlc/gen/c_body_gen_base_cb.h
index a9d7ef1..a9d7ef1 100644
--- a/idlc/c_gen/c_body_gen_base_cb.h
+++ b/idlc/gen/c_body_gen_base_cb.h
diff --git a/idlc/c_gen/c_gen_base.cc b/idlc/gen/c_gen_base.cc
index 0b975f2..4741359 100644
--- a/idlc/c_gen/c_gen_base.cc
+++ b/idlc/gen/c_gen_base.cc
@@ -20,10 +20,10 @@
#include <sstream>
#include <algorithm>
-#include "idlc/c_gen/c_gen_base.h"
+#include "idlc/gen/c_gen_base.h"
namespace {
-#include "idlc/c_gen/c_gen_base_cb.h"
+#include "idlc/gen/c_gen_base_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_gen_base.h b/idlc/gen/c_gen_base.h
index 1bc2ae3..caec145 100644
--- a/idlc/c_gen/c_gen_base.h
+++ b/idlc/gen/c_gen_base.h
@@ -21,9 +21,9 @@
#include <string>
#include <map>
-#include "idlc/type.h"
-#include "idlc/structure.h"
-#include "idlc/generator.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/structure.h"
+#include "idlc/gen/generator.h"
namespace tidl {
diff --git a/idlc/c_gen/c_gen_base_cb.h b/idlc/gen/c_gen_base_cb.h
index 5af4d66..5af4d66 100644
--- a/idlc/c_gen/c_gen_base_cb.h
+++ b/idlc/gen/c_gen_base_cb.h
diff --git a/idlc/c_gen/c_header_gen_base.cc b/idlc/gen/c_header_gen_base.cc
index ee86046..f402fe0 100644
--- a/idlc/c_gen/c_header_gen_base.cc
+++ b/idlc/gen/c_header_gen_base.cc
@@ -16,10 +16,10 @@
#include <vector>
-#include "idlc/c_gen/c_header_gen_base.h"
+#include "idlc/gen/c_header_gen_base.h"
namespace {
-#include "idlc/c_gen/c_header_gen_base_cb.h"
+#include "idlc/gen/c_header_gen_base_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_header_gen_base.h b/idlc/gen/c_header_gen_base.h
index 494fac4..4e2ad35 100644
--- a/idlc/c_gen/c_header_gen_base.h
+++ b/idlc/gen/c_header_gen_base.h
@@ -21,7 +21,7 @@
#include <string>
#include <map>
-#include "idlc/c_gen/c_gen_base.h"
+#include "idlc/gen/c_gen_base.h"
namespace tidl {
diff --git a/idlc/c_gen/c_header_gen_base_cb.h b/idlc/gen/c_header_gen_base_cb.h
index e0229f5..e0229f5 100644
--- a/idlc/c_gen/c_header_gen_base_cb.h
+++ b/idlc/gen/c_header_gen_base_cb.h
diff --git a/idlc/c_gen/c_proxy_body_gen.cc b/idlc/gen/c_proxy_body_gen.cc
index 39683d4..662b57e 100644
--- a/idlc/c_gen/c_proxy_body_gen.cc
+++ b/idlc/gen/c_proxy_body_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/c_gen/c_proxy_body_gen.h"
+#include "idlc/gen/c_proxy_body_gen.h"
namespace {
-#include "idlc/c_gen/c_proxy_body_gen_cb.h"
+#include "idlc/gen/c_proxy_body_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_proxy_body_gen.h b/idlc/gen/c_proxy_body_gen.h
index 04dd55e..5e07115 100644
--- a/idlc/c_gen/c_proxy_body_gen.h
+++ b/idlc/gen/c_proxy_body_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/c_gen/c_body_gen_base.h"
+#include "idlc/gen/c_body_gen_base.h"
namespace tidl {
diff --git a/idlc/c_gen/c_proxy_body_gen_cb.h b/idlc/gen/c_proxy_body_gen_cb.h
index 7eee658..7eee658 100644
--- a/idlc/c_gen/c_proxy_body_gen_cb.h
+++ b/idlc/gen/c_proxy_body_gen_cb.h
diff --git a/idlc/c_gen/c_proxy_header_gen.cc b/idlc/gen/c_proxy_header_gen.cc
index e9eac53..64bfab4 100644
--- a/idlc/c_gen/c_proxy_header_gen.cc
+++ b/idlc/gen/c_proxy_header_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/c_gen/c_proxy_header_gen.h"
+#include "idlc/gen/c_proxy_header_gen.h"
namespace {
-#include "idlc/c_gen/c_proxy_header_gen_cb.h"
+#include "idlc/gen/c_proxy_header_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_proxy_header_gen.h b/idlc/gen/c_proxy_header_gen.h
index 04f3abf..800d67e 100644
--- a/idlc/c_gen/c_proxy_header_gen.h
+++ b/idlc/gen/c_proxy_header_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/c_gen/c_header_gen_base.h"
+#include "idlc/gen/c_header_gen_base.h"
namespace tidl {
diff --git a/idlc/c_gen/c_proxy_header_gen_cb.h b/idlc/gen/c_proxy_header_gen_cb.h
index 4fe6daf..4fe6daf 100644
--- a/idlc/c_gen/c_proxy_header_gen_cb.h
+++ b/idlc/gen/c_proxy_header_gen_cb.h
diff --git a/idlc/c_gen/c_stub_body_gen.cc b/idlc/gen/c_stub_body_gen.cc
index bfa6095..f9ebec9 100644
--- a/idlc/c_gen/c_stub_body_gen.cc
+++ b/idlc/gen/c_stub_body_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/c_gen/c_stub_body_gen.h"
+#include "idlc/gen/c_stub_body_gen.h"
namespace {
-#include "idlc/c_gen/c_stub_body_gen_cb.h"
+#include "idlc/gen/c_stub_body_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_stub_body_gen.h b/idlc/gen/c_stub_body_gen.h
index 69c88f9..16bf22e 100644
--- a/idlc/c_gen/c_stub_body_gen.h
+++ b/idlc/gen/c_stub_body_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/c_gen/c_body_gen_base.h"
+#include "idlc/gen/c_body_gen_base.h"
namespace tidl {
diff --git a/idlc/c_gen/c_stub_body_gen_cb.h b/idlc/gen/c_stub_body_gen_cb.h
index 7c77b83..7c77b83 100644
--- a/idlc/c_gen/c_stub_body_gen_cb.h
+++ b/idlc/gen/c_stub_body_gen_cb.h
diff --git a/idlc/c_gen/c_stub_header_gen.cc b/idlc/gen/c_stub_header_gen.cc
index 1936606..426cd6d 100644
--- a/idlc/c_gen/c_stub_header_gen.cc
+++ b/idlc/gen/c_stub_header_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/c_gen/c_stub_header_gen.h"
+#include "idlc/gen/c_stub_header_gen.h"
namespace {
-#include "idlc/c_gen/c_stub_header_gen_cb.h"
+#include "idlc/gen/c_stub_header_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/c_gen/c_stub_header_gen.h b/idlc/gen/c_stub_header_gen.h
index 3564967..43d2e53 100644
--- a/idlc/c_gen/c_stub_header_gen.h
+++ b/idlc/gen/c_stub_header_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/c_gen/c_header_gen_base.h"
+#include "idlc/gen/c_header_gen_base.h"
namespace tidl {
diff --git a/idlc/c_gen/c_stub_header_gen_cb.h b/idlc/gen/c_stub_header_gen_cb.h
index 49e37f0..49e37f0 100644
--- a/idlc/c_gen/c_stub_header_gen_cb.h
+++ b/idlc/gen/c_stub_header_gen_cb.h
diff --git a/idlc/cpp_gen/cpp_gen_base.cc b/idlc/gen/cpp_gen_base.cc
index d18fbd1..b9ffb69 100644
--- a/idlc/cpp_gen/cpp_gen_base.cc
+++ b/idlc/gen/cpp_gen_base.cc
@@ -18,10 +18,10 @@
#include <vector>
#include <utility>
-#include "idlc/cpp_gen/cpp_gen_base.h"
+#include "idlc/gen/cpp_gen_base.h"
namespace {
-#include "idlc/cpp_gen/cpp_gen_base_cb.h"
+#include "idlc/gen/cpp_gen_base_cb.h"
}
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_gen_base.h b/idlc/gen/cpp_gen_base.h
index c59e6bc..d0e37d1 100644
--- a/idlc/cpp_gen/cpp_gen_base.h
+++ b/idlc/gen/cpp_gen_base.h
@@ -21,9 +21,9 @@
#include <string>
#include <map>
-#include "idlc/type.h"
-#include "idlc/structure.h"
-#include "idlc/generator.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/structure.h"
+#include "idlc/gen/generator.h"
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_gen_base_cb.h b/idlc/gen/cpp_gen_base_cb.h
index 56216c4..56216c4 100644
--- a/idlc/cpp_gen/cpp_gen_base_cb.h
+++ b/idlc/gen/cpp_gen_base_cb.h
diff --git a/idlc/cpp_gen/cpp_proxy_body_gen.cc b/idlc/gen/cpp_proxy_body_gen.cc
index 0fe8607..c6afe03 100644
--- a/idlc/cpp_gen/cpp_proxy_body_gen.cc
+++ b/idlc/gen/cpp_proxy_body_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/cpp_gen/cpp_proxy_body_gen.h"
+#include "idlc/gen/cpp_proxy_body_gen.h"
namespace {
-#include "idlc/cpp_gen/cpp_proxy_body_gen_cb.h"
+#include "idlc/gen/cpp_proxy_body_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_proxy_body_gen.h b/idlc/gen/cpp_proxy_body_gen.h
index 0b6c6d4..b6e7c1d 100644
--- a/idlc/cpp_gen/cpp_proxy_body_gen.h
+++ b/idlc/gen/cpp_proxy_body_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cpp_gen/cpp_gen_base.h"
+#include "idlc/gen/cpp_gen_base.h"
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_proxy_body_gen_cb.h b/idlc/gen/cpp_proxy_body_gen_cb.h
index b5dbefd..b5dbefd 100644
--- a/idlc/cpp_gen/cpp_proxy_body_gen_cb.h
+++ b/idlc/gen/cpp_proxy_body_gen_cb.h
diff --git a/idlc/cpp_gen/cpp_proxy_header_gen.cc b/idlc/gen/cpp_proxy_header_gen.cc
index 153cbeb..305cabc 100644
--- a/idlc/cpp_gen/cpp_proxy_header_gen.cc
+++ b/idlc/gen/cpp_proxy_header_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/cpp_gen/cpp_proxy_header_gen.h"
+#include "idlc/gen/cpp_proxy_header_gen.h"
namespace {
-#include "idlc/cpp_gen/cpp_proxy_header_gen_cb.h"
+#include "idlc/gen/cpp_proxy_header_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_proxy_header_gen.h b/idlc/gen/cpp_proxy_header_gen.h
index 96cb19c..e3ac8b5 100644
--- a/idlc/cpp_gen/cpp_proxy_header_gen.h
+++ b/idlc/gen/cpp_proxy_header_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cpp_gen/cpp_gen_base.h"
+#include "idlc/gen/cpp_gen_base.h"
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_proxy_header_gen_cb.h b/idlc/gen/cpp_proxy_header_gen_cb.h
index 0bf19ee..0bf19ee 100644
--- a/idlc/cpp_gen/cpp_proxy_header_gen_cb.h
+++ b/idlc/gen/cpp_proxy_header_gen_cb.h
diff --git a/idlc/cpp_gen/cpp_stub_body_gen.cc b/idlc/gen/cpp_stub_body_gen.cc
index f564f9e..93308d8 100644
--- a/idlc/cpp_gen/cpp_stub_body_gen.cc
+++ b/idlc/gen/cpp_stub_body_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/cpp_gen/cpp_stub_body_gen.h"
+#include "idlc/gen/cpp_stub_body_gen.h"
namespace {
-#include "idlc/cpp_gen/cpp_stub_body_gen_cb.h"
+#include "idlc/gen/cpp_stub_body_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_stub_body_gen.h b/idlc/gen/cpp_stub_body_gen.h
index fa8b7cc..7db4dec 100644
--- a/idlc/cpp_gen/cpp_stub_body_gen.h
+++ b/idlc/gen/cpp_stub_body_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cpp_gen/cpp_gen_base.h"
+#include "idlc/gen/cpp_gen_base.h"
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_stub_body_gen_cb.h b/idlc/gen/cpp_stub_body_gen_cb.h
index d3fad11..d3fad11 100644
--- a/idlc/cpp_gen/cpp_stub_body_gen_cb.h
+++ b/idlc/gen/cpp_stub_body_gen_cb.h
diff --git a/idlc/cpp_gen/cpp_stub_header_gen.cc b/idlc/gen/cpp_stub_header_gen.cc
index a4e591b..0e5689e 100644
--- a/idlc/cpp_gen/cpp_stub_header_gen.cc
+++ b/idlc/gen/cpp_stub_header_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/cpp_gen/cpp_stub_header_gen.h"
+#include "idlc/gen/cpp_stub_header_gen.h"
namespace {
-#include "idlc/cpp_gen/cpp_stub_header_gen_cb.h"
+#include "idlc/gen/cpp_stub_header_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_stub_header_gen.h b/idlc/gen/cpp_stub_header_gen.h
index 52bebfe..db8d82b 100644
--- a/idlc/cpp_gen/cpp_stub_header_gen.h
+++ b/idlc/gen/cpp_stub_header_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cpp_gen/cpp_gen_base.h"
+#include "idlc/gen/cpp_gen_base.h"
namespace tidl {
diff --git a/idlc/cpp_gen/cpp_stub_header_gen_cb.h b/idlc/gen/cpp_stub_header_gen_cb.h
index 8cb4c1f..8cb4c1f 100644
--- a/idlc/cpp_gen/cpp_stub_header_gen_cb.h
+++ b/idlc/gen/cpp_stub_header_gen_cb.h
diff --git a/idlc/cs_gen/cs_cb_interop.h b/idlc/gen/cs_cb_interop.h
index 4e6cf90..4e6cf90 100644
--- a/idlc/cs_gen/cs_cb_interop.h
+++ b/idlc/gen/cs_cb_interop.h
diff --git a/idlc/cs_gen/cs_cb_rpc_port.h b/idlc/gen/cs_cb_rpc_port.h
index 573aebb..573aebb 100644
--- a/idlc/cs_gen/cs_cb_rpc_port.h
+++ b/idlc/gen/cs_cb_rpc_port.h
diff --git a/idlc/cs_gen/cs_cb_version.h b/idlc/gen/cs_cb_version.h
index c0102a4..c0102a4 100644
--- a/idlc/cs_gen/cs_cb_version.h
+++ b/idlc/gen/cs_cb_version.h
diff --git a/idlc/cs_gen/cs_gen_base.cc b/idlc/gen/cs_gen_base.cc
index d1f7b65..bb1e5bb 100644
--- a/idlc/cs_gen/cs_gen_base.cc
+++ b/idlc/gen/cs_gen_base.cc
@@ -17,12 +17,12 @@
#include <ctime>
#include <vector>
-#include "idlc/cs_gen/cs_gen_base.h"
+#include "idlc/gen/cs_gen_base.h"
namespace {
-#include "idlc/cs_gen/cs_cb_version.h"
-#include "idlc/cs_gen/cs_gen_base_cb.h"
-#include "idlc/cs_gen/cs_cb_rpc_port.h"
+#include "idlc/gen/cs_cb_version.h"
+#include "idlc/gen/cs_gen_base_cb.h"
+#include "idlc/gen/cs_cb_rpc_port.h"
}
namespace tidl {
diff --git a/idlc/cs_gen/cs_gen_base.h b/idlc/gen/cs_gen_base.h
index cbc35c9..c7c4cdd 100644
--- a/idlc/cs_gen/cs_gen_base.h
+++ b/idlc/gen/cs_gen_base.h
@@ -21,9 +21,9 @@
#include <string>
#include <map>
-#include "idlc/type.h"
-#include "idlc/structure.h"
-#include "idlc/generator.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/structure.h"
+#include "idlc/gen/generator.h"
namespace tidl {
diff --git a/idlc/cs_gen/cs_gen_base_cb.h b/idlc/gen/cs_gen_base_cb.h
index aabc490..aabc490 100644
--- a/idlc/cs_gen/cs_gen_base_cb.h
+++ b/idlc/gen/cs_gen_base_cb.h
diff --git a/idlc/cs_gen/cs_lib_gen.cc b/idlc/gen/cs_lib_gen.cc
index 8f2eba0..124aa3e 100644
--- a/idlc/cs_gen/cs_lib_gen.cc
+++ b/idlc/gen/cs_lib_gen.cc
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-#include "idlc/cs_gen/cs_lib_gen.h"
+#include "idlc/gen/cs_lib_gen.h"
namespace {
-#include "idlc/cs_gen/cs_cb_rpc_port.h"
-#include "idlc/cs_gen/cs_cb_interop.h"
+#include "idlc/gen/cs_cb_rpc_port.h"
+#include "idlc/gen/cs_cb_interop.h"
}
namespace tidl {
diff --git a/idlc/cs_gen/cs_lib_gen.h b/idlc/gen/cs_lib_gen.h
index 83cc151..f4c0719 100644
--- a/idlc/cs_gen/cs_lib_gen.h
+++ b/idlc/gen/cs_lib_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cs_gen/cs_gen_base.h"
+#include "idlc/gen/cs_gen_base.h"
namespace tidl {
diff --git a/idlc/cs_gen/cs_proxy_gen.cc b/idlc/gen/cs_proxy_gen.cc
index 23e24f3..280decd 100644
--- a/idlc/cs_gen/cs_proxy_gen.cc
+++ b/idlc/gen/cs_proxy_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/cs_gen/cs_proxy_gen.h"
+#include "idlc/gen/cs_proxy_gen.h"
namespace {
-#include "idlc/cs_gen/cs_proxy_gen_cb.h"
+#include "idlc/gen/cs_proxy_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/cs_gen/cs_proxy_gen.h b/idlc/gen/cs_proxy_gen.h
index a5a99e0..3b9b758 100644
--- a/idlc/cs_gen/cs_proxy_gen.h
+++ b/idlc/gen/cs_proxy_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cs_gen/cs_gen_base.h"
+#include "idlc/gen/cs_gen_base.h"
namespace tidl {
diff --git a/idlc/cs_gen/cs_proxy_gen_cb.h b/idlc/gen/cs_proxy_gen_cb.h
index a9f51ff..a9f51ff 100644
--- a/idlc/cs_gen/cs_proxy_gen_cb.h
+++ b/idlc/gen/cs_proxy_gen_cb.h
diff --git a/idlc/cs_gen/cs_stub_gen.cc b/idlc/gen/cs_stub_gen.cc
index e11800d..04b68b3 100644
--- a/idlc/cs_gen/cs_stub_gen.cc
+++ b/idlc/gen/cs_stub_gen.cc
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-#include "idlc/cs_gen/cs_stub_gen.h"
+#include "idlc/gen/cs_stub_gen.h"
namespace {
-#include "idlc/cs_gen/cs_stub_gen_cb.h"
+#include "idlc/gen/cs_stub_gen_cb.h"
}
namespace tidl {
diff --git a/idlc/cs_gen/cs_stub_gen.h b/idlc/gen/cs_stub_gen.h
index ba47c43..b697e4e 100644
--- a/idlc/cs_gen/cs_stub_gen.h
+++ b/idlc/gen/cs_stub_gen.h
@@ -20,7 +20,7 @@
#include <memory>
#include <string>
-#include "idlc/cs_gen/cs_gen_base.h"
+#include "idlc/gen/cs_gen_base.h"
namespace tidl {
diff --git a/idlc/cs_gen/cs_stub_gen_cb.h b/idlc/gen/cs_stub_gen_cb.h
index 3be382a..3be382a 100644
--- a/idlc/cs_gen/cs_stub_gen_cb.h
+++ b/idlc/gen/cs_stub_gen_cb.h
diff --git a/idlc/generator.cc b/idlc/gen/generator.cc
index 41f41be..19bcc0b 100644
--- a/idlc/generator.cc
+++ b/idlc/gen/generator.cc
@@ -16,12 +16,12 @@
#include <sstream>
-#include "idlc/generator.h"
-#include "idlc/block.h"
-#include "idlc/interface.h"
-#include "idlc/structure.h"
-#include "idlc/declaration.h"
-#include "idlc/attribute.h"
+#include "idlc/gen/generator.h"
+#include "idlc/ast/block.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/attribute.h"
namespace tidl {
diff --git a/idlc/generator.h b/idlc/gen/generator.h
index ed6b4ee..249b594 100644
--- a/idlc/generator.h
+++ b/idlc/gen/generator.h
@@ -23,9 +23,9 @@
#include <memory>
#include <utility>
-#include "idlc/document.h"
-#include "idlc/parameter.h"
-#include "idlc/type.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/parameter.h"
+#include "idlc/ast/type.h"
namespace tidl {
diff --git a/idlc/main.cc b/idlc/main.cc
index 19b4df5..2c405dd 100644
--- a/idlc/main.cc
+++ b/idlc/main.cc
@@ -20,18 +20,18 @@
#include <cstring>
#include <memory>
-#include "idlc/parser.h"
-#include "idlc/cs_gen/cs_proxy_gen.h"
-#include "idlc/cs_gen/cs_stub_gen.h"
-#include "idlc/cs_gen/cs_lib_gen.h"
-#include "idlc/c_gen/c_proxy_header_gen.h"
-#include "idlc/c_gen/c_proxy_body_gen.h"
-#include "idlc/c_gen/c_stub_header_gen.h"
-#include "idlc/c_gen/c_stub_body_gen.h"
-#include "idlc/cpp_gen/cpp_proxy_header_gen.h"
-#include "idlc/cpp_gen/cpp_proxy_body_gen.h"
-#include "idlc/cpp_gen/cpp_stub_header_gen.h"
-#include "idlc/cpp_gen/cpp_stub_body_gen.h"
+#include "idlc/ast/parser.h"
+#include "idlc/gen/cs_proxy_gen.h"
+#include "idlc/gen/cs_stub_gen.h"
+#include "idlc/gen/cs_lib_gen.h"
+#include "idlc/gen/c_proxy_header_gen.h"
+#include "idlc/gen/c_proxy_body_gen.h"
+#include "idlc/gen/c_stub_header_gen.h"
+#include "idlc/gen/c_stub_body_gen.h"
+#include "idlc/gen/cpp_proxy_header_gen.h"
+#include "idlc/gen/cpp_proxy_body_gen.h"
+#include "idlc/gen/cpp_stub_header_gen.h"
+#include "idlc/gen/cpp_stub_body_gen.h"
namespace {
diff --git a/unit_tests/CMakeLists.txt b/unit_tests/CMakeLists.txt
index a56a7d2..96849aa 100644
--- a/unit_tests/CMakeLists.txt
+++ b/unit_tests/CMakeLists.txt
@@ -14,27 +14,27 @@ INCLUDE_DIRECTORIES(${GTEST_INCLUDE_DIRS})
LINK_DIRECTORIES(${GTEST_LIBRARY_DIRS})
SET(TIDLC_SOURCES
- ${CMAKE_SOURCE_DIR}/idlc/document.cc
- ${CMAKE_SOURCE_DIR}/idlc/declaration.cc
- ${CMAKE_SOURCE_DIR}/idlc/interface.cc
- ${CMAKE_SOURCE_DIR}/idlc/type.cc
- ${CMAKE_SOURCE_DIR}/idlc/parameter.cc
- ${CMAKE_SOURCE_DIR}/idlc/element.cc
- ${CMAKE_SOURCE_DIR}/idlc/structure.cc
- ${CMAKE_SOURCE_DIR}/idlc/block.cc
- ${CMAKE_SOURCE_DIR}/idlc/generator.cc
- ${CMAKE_SOURCE_DIR}/idlc/parser.cc
- ${CMAKE_SOURCE_DIR}/idlc/attribute.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/document.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/declaration.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/interface.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/type.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/parameter.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/element.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/structure.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/block.cc
+ ${CMAKE_SOURCE_DIR}/idlc/gen/generator.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/parser.cc
+ ${CMAKE_SOURCE_DIR}/idlc/ast/attribute.cc
)
ADD_DEFINITIONS("-DFULLVER=\"${FULLVER}\"")
AUX_SOURCE_DIRECTORY(. UNIT_TESTS_SOURCES)
AUX_SOURCE_DIRECTORY(cs_gen CS_GEN_UNIT_TESTS_SOURCES)
-AUX_SOURCE_DIRECTORY(${CMAKE_SOURCE_DIR}/idlc/cs_gen CS_GEN_SOURCES)
+AUX_SOURCE_DIRECTORY(${CMAKE_SOURCE_DIR}/idlc/gen CS_GEN_SOURCES)
-FLEX_TARGET(TIDLC ${CMAKE_SOURCE_DIR}/idlc/tidlc.ll ${CMAKE_SOURCE_DIR}/idlc/tidlc_l.cpp)
-BISON_TARGET(TIDLC ${CMAKE_SOURCE_DIR}/idlc/tidlc.yy ${CMAKE_SOURCE_DIR}/idlc/tidlc_y.cpp)
+FLEX_TARGET(TIDLC ${CMAKE_SOURCE_DIR}/idlc/ast/tidlc.ll ${CMAKE_SOURCE_DIR}/idlc/ast/tidlc_l.cpp)
+BISON_TARGET(TIDLC ${CMAKE_SOURCE_DIR}/idlc/ast/tidlc.yy ${CMAKE_SOURCE_DIR}/idlc/ast/tidlc_y.cpp)
ADD_EXECUTABLE(${TIDL_UNIT_TESTS}
${BISON_TIDLC_OUTPUTS}
diff --git a/unit_tests/attribute_unittest.cc b/unit_tests/attribute_unittest.cc
index 506a2b7..e001f4c 100644
--- a/unit_tests/attribute_unittest.cc
+++ b/unit_tests/attribute_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/attribute.h"
+#include "idlc/ast/attribute.h"
class AttributeTest : public testing::Test {
public:
diff --git a/unit_tests/block_unittest.cc b/unit_tests/block_unittest.cc
index 589b378..0659344 100644
--- a/unit_tests/block_unittest.cc
+++ b/unit_tests/block_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/block.h"
+#include "idlc/ast/block.h"
class BlockTest : public testing::Test {
public:
diff --git a/unit_tests/cs_gen/cs_proxy_gen_unittest.cc b/unit_tests/cs_gen/cs_proxy_gen_unittest.cc
index b9b898c..fd247cf 100644
--- a/unit_tests/cs_gen/cs_proxy_gen_unittest.cc
+++ b/unit_tests/cs_gen/cs_proxy_gen_unittest.cc
@@ -18,8 +18,8 @@
#include <iostream>
-#include "idlc/parser.h"
-#include "idlc/cs_gen/cs_proxy_gen.h"
+#include "idlc/ast/parser.h"
+#include "idlc/gen/cs_proxy_gen.h"
class CsProxyGenTest : public testing::Test {
public:
diff --git a/unit_tests/cs_gen/cs_stub_gen_unittest.cc b/unit_tests/cs_gen/cs_stub_gen_unittest.cc
index ea5643e..512c6de 100644
--- a/unit_tests/cs_gen/cs_stub_gen_unittest.cc
+++ b/unit_tests/cs_gen/cs_stub_gen_unittest.cc
@@ -18,8 +18,8 @@
#include <iostream>
-#include "idlc/parser.h"
-#include "idlc/cs_gen/cs_stub_gen.h"
+#include "idlc/ast/parser.h"
+#include "idlc/gen/cs_stub_gen.h"
class CsStubGenTest : public testing::Test {
public:
diff --git a/unit_tests/declaration_unittest.cc b/unit_tests/declaration_unittest.cc
index 2e5c9a4..776341d 100644
--- a/unit_tests/declaration_unittest.cc
+++ b/unit_tests/declaration_unittest.cc
@@ -18,9 +18,9 @@
#include <iostream>
-#include "idlc/declaration.h"
-#include "idlc/type.h"
-#include "idlc/parameter.h"
+#include "idlc/ast/declaration.h"
+#include "idlc/ast/type.h"
+#include "idlc/ast/parameter.h"
class DeclarationTest : public testing::Test {
public:
diff --git a/unit_tests/document_unittest.cc b/unit_tests/document_unittest.cc
index b27ed0b..31e6c1b 100644
--- a/unit_tests/document_unittest.cc
+++ b/unit_tests/document_unittest.cc
@@ -18,8 +18,8 @@
#include <iostream>
-#include "idlc/document.h"
-#include "idlc/block.h"
+#include "idlc/ast/document.h"
+#include "idlc/ast/block.h"
class DocumentTest : public testing::Test {
public:
diff --git a/unit_tests/element_unittest.cc b/unit_tests/element_unittest.cc
index fb399a8..8ef351c 100644
--- a/unit_tests/element_unittest.cc
+++ b/unit_tests/element_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/element.h"
+#include "idlc/ast/element.h"
class ElementTest : public testing::Test {
public:
diff --git a/unit_tests/generator_unittest.cc b/unit_tests/generator_unittest.cc
index dd15a1c..7573025 100644
--- a/unit_tests/generator_unittest.cc
+++ b/unit_tests/generator_unittest.cc
@@ -19,10 +19,10 @@
#include <iostream>
#include <memory>
-#include "idlc/generator.h"
-#include "idlc/interface.h"
-#include "idlc/structure.h"
-#include "idlc/attribute.h"
+#include "idlc/gen/generator.h"
+#include "idlc/ast/interface.h"
+#include "idlc/ast/structure.h"
+#include "idlc/ast/attribute.h"
class SampleGenerator : public tidl::Generator {
public:
diff --git a/unit_tests/interface_unittest.cc b/unit_tests/interface_unittest.cc
index c31778f..780aca5 100644
--- a/unit_tests/interface_unittest.cc
+++ b/unit_tests/interface_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/interface.h"
+#include "idlc/ast/interface.h"
class InterfaceTest : public testing::Test {
public:
diff --git a/unit_tests/parser_unittest.cc b/unit_tests/parser_unittest.cc
index e838957..748e33a 100644
--- a/unit_tests/parser_unittest.cc
+++ b/unit_tests/parser_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/parser.h"
+#include "idlc/ast/parser.h"
extern int gargc;
extern char** gargv;
diff --git a/unit_tests/structure_unittest.cc b/unit_tests/structure_unittest.cc
index 563e851..4e68e98 100644
--- a/unit_tests/structure_unittest.cc
+++ b/unit_tests/structure_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/structure.h"
+#include "idlc/ast/structure.h"
class StructureTest : public testing::Test {
public:
diff --git a/unit_tests/type_unittest.cc b/unit_tests/type_unittest.cc
index fe07b47..f08e7b3 100644
--- a/unit_tests/type_unittest.cc
+++ b/unit_tests/type_unittest.cc
@@ -18,7 +18,7 @@
#include <iostream>
-#include "idlc/type.h"
+#include "idlc/ast/type.h"
class TokenTest : public testing::Test {
public: