summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--slicer/test/preprocessor.cpp4
-rw-r--r--slicer/test/serializers.cpp3
-rw-r--r--slicer/test/structs.ice1
-rw-r--r--slicer/tool/parser.cpp7
4 files changed, 12 insertions, 3 deletions
diff --git a/slicer/test/preprocessor.cpp b/slicer/test/preprocessor.cpp
index eddeb31..2513f99 100644
--- a/slicer/test/preprocessor.cpp
+++ b/slicer/test/preprocessor.cpp
@@ -12,7 +12,7 @@
using ComponentsCount = std::map<std::string, unsigned int>;
ComponentsCount COMPONENTS_IN_TEST_ICE = {{"classtype.ice", 2}, {"classes.ice", 3}, {"collections.ice", 5},
{"enums.ice", 2}, {"inheritance.ice", 12}, {"interfaces.ice", 0}, {"json.ice", 2}, {"locals.ice", 7},
- {"optionals.ice", 2}, {"structs.ice", 4}, {"types.ice", 3}, {"xml.ice", 5}};
+ {"optionals.ice", 2}, {"structs.ice", 5}, {"types.ice", 3}, {"xml.ice", 5}};
unsigned int
total()
@@ -21,7 +21,7 @@ total()
COMPONENTS_IN_TEST_ICE.begin(), COMPONENTS_IN_TEST_ICE.end(), 0U, [](auto & t, auto && c) {
return t += c.second;
});
- BOOST_CHECK_EQUAL(47, t);
+ BOOST_CHECK_EQUAL(48, t);
return t;
}
diff --git a/slicer/test/serializers.cpp b/slicer/test/serializers.cpp
index c8f8390..53c6965 100644
--- a/slicer/test/serializers.cpp
+++ b/slicer/test/serializers.cpp
@@ -694,5 +694,6 @@ BOOST_AUTO_TEST_CASE(enum_lookups)
BOOST_AUTO_TEST_CASE(sequence_element_in_same_slice_link_bug)
{
// Link error when sequence element type defined in same slice.
- Slicer::ModelPartForSequence<TestModule::Classes> mp(nullptr);
+ Slicer::ModelPartForSequence<TestModule::Classes> mpClasses(nullptr);
+ Slicer::ModelPartForSequence<TestModule::Dates> mpDates(nullptr);
}
diff --git a/slicer/test/structs.ice b/slicer/test/structs.ice
index fcd17fe..8edb585 100644
--- a/slicer/test/structs.ice
+++ b/slicer/test/structs.ice
@@ -29,6 +29,7 @@ module TestModule {
StructType str;
int simp;
};
+ sequence<IsoDate> Dates;
};
#endif
diff --git a/slicer/tool/parser.cpp b/slicer/tool/parser.cpp
index d2288ae..3d0505a 100644
--- a/slicer/tool/parser.cpp
+++ b/slicer/tool/parser.cpp
@@ -31,6 +31,13 @@ namespace Slicer {
return false;
};
+ bool
+ visitStructStart(const Slice::StructPtr & s) override
+ {
+ fprintbf(cpp, "struct ICE_CLASS(JAM_DLL_PUBLIC) %s;\n", s->name());
+ return false;
+ };
+
void
visitModuleEnd(const Slice::ModulePtr & m) override
{