diff --git a/.circleci/config.yml b/.circleci/config.yml index 0ee638c..dba1039 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -21,6 +21,13 @@ workflows: oid_test_args: "-ftype-graph" tests_regex: "OidIntegration\\..*" exclude_regex: ".*inheritance_polymorphic.*" + - test: + name: test-typed-data-segment-gcc + requires: + - build-gcc + oid_test_args: "-ftyped-data-segment" + tests_regex: "OidIntegration\\..*" + exclude_regex: ".*inheritance_polymorphic.*|.*thrift_.*|.*std_vector_del_allocator_a|.*cycles_.*" - coverage: name: coverage requires: @@ -29,6 +36,10 @@ workflows: name: coverage-type-graph requires: - test-type-graph-gcc + - coverage: + name: coverage-typed-data-sgement + requires: + - test-typed-data-segment-gcc - build: name: build-clang diff --git a/oi/OIUtils.cpp b/oi/OIUtils.cpp index da5eec1..1368695 100644 --- a/oi/OIUtils.cpp +++ b/oi/OIUtils.cpp @@ -163,6 +163,12 @@ std::optional processConfigFile( if (featuresSet[Feature::TypedDataSegment] && !featuresSet[Feature::TypeGraph]) { + if (auto search = featureMap.find(Feature::TypeGraph); + search != featureMap.end() && !search->second) { + LOG(ERROR) << "TypedDataSegment feature requires TypeGraph feature to be " + "enabled but it was explicitly disabled!"; + return {}; + } featuresSet[Feature::TypeGraph] = true; LOG(WARNING) << "TypedDataSegment feature requires TypeGraph feature to be " "enabled, enabling now."; diff --git a/test/integration/arrays.toml b/test/integration/arrays.toml index 8f3a7ae..4e62771 100644 --- a/test/integration/arrays.toml +++ b/test/integration/arrays.toml @@ -44,7 +44,7 @@ definitions = ''' "dynamicSize":0 }]}]''' [cases.multidim_legacy] # Test for legacy behaviour. Remove with OICodeGen - cli_options = ["-Ftype-graph"] + cli_options = ["-Ftype-graph", "-Ftyped-data-segment"] param_types = ["const MultiDim&"] setup = "return {};" expect_json = '''[{