From 8286ac511144e4f17d34eac9affb97e50646344a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Wed, 23 Jul 2014 15:25:44 +0200 Subject: Imported Upstream version 4.0.0 --- xsd/tests/cxx/tree/naming/knr/driver.cxx | 16 +++++++++++++--- xsd/tests/cxx/tree/naming/knr/makefile | 14 +++++++++----- 2 files changed, 22 insertions(+), 8 deletions(-) (limited to 'xsd/tests/cxx/tree/naming/knr') diff --git a/xsd/tests/cxx/tree/naming/knr/driver.cxx b/xsd/tests/cxx/tree/naming/knr/driver.cxx index fff944b..5038d7b 100644 --- a/xsd/tests/cxx/tree/naming/knr/driver.cxx +++ b/xsd/tests/cxx/tree/naming/knr/driver.cxx @@ -1,12 +1,10 @@ // file : tests/cxx/tree/naming/knr/driver.cxx -// author : Boris Kolpackov -// copyright : Copyright (c) 2006-2010 Code Synthesis Tools CC +// copyright : Copyright (c) 2006-2014 Code Synthesis Tools CC // license : GNU GPL v2 + exceptions; see accompanying LICENSE file // Test K&R naming style. // -#include // std::auto_ptr #include #include @@ -29,6 +27,7 @@ main () { gender::value v; v = gender::female; + XSD_UNUSED (v); } // Anonymous type. @@ -49,6 +48,8 @@ main () // { type::foo_type* p = 0; + XSD_UNUSED (p); + type::foo_optional o; if (t.foo ().present ()) @@ -61,6 +62,7 @@ main () // { type::bar_type* p = 0; + XSD_UNUSED (p); if (t.bar () != "bar") return 1; @@ -72,9 +74,13 @@ main () // { type::baz_type* p = 0; + XSD_UNUSED (p); + type::baz_sequence s; type::baz_iterator i (s.begin ()); type::baz_const_iterator ci (s.begin ()); + XSD_UNUSED (i); + XSD_UNUSED (ci); if (t.baz () != s) return 1; @@ -88,6 +94,8 @@ main () type::any_sequence s (t.dom_document ()); type::any_iterator i (s.begin ()); type::any_const_iterator ci (s.begin ()); + XSD_UNUSED (i); + XSD_UNUSED (ci); if (t.any () != s) return 1; @@ -112,6 +120,8 @@ main () type::any_attribute_set s (t.dom_document ()); type::any_attribute_iterator i (s.begin ()); type::any_attribute_const_iterator ci (s.begin ()); + XSD_UNUSED (i); + XSD_UNUSED (ci); if (t.any_attribute () != s) return 1; diff --git a/xsd/tests/cxx/tree/naming/knr/makefile b/xsd/tests/cxx/tree/naming/knr/makefile index ac9e75e..d8ecbab 100644 --- a/xsd/tests/cxx/tree/naming/knr/makefile +++ b/xsd/tests/cxx/tree/naming/knr/makefile @@ -1,6 +1,5 @@ # file : tests/cxx/tree/naming/knr/makefile -# author : Boris Kolpackov -# copyright : Copyright (c) 2006-2010 Code Synthesis Tools CC +# copyright : Copyright (c) 2006-2014 Code Synthesis Tools CC # license : GNU GPL v2 + exceptions; see accompanying LICENSE file include $(dir $(lastword $(MAKEFILE_LIST)))../../../../../build/bootstrap.make @@ -27,7 +26,7 @@ $(call import,\ # $(driver): $(obj) $(xerces_c.l) -$(obj) $(dep): cpp_options := -I$(src_root)/libxsd +$(obj) $(dep): cpp_options := -I$(out_base) -I$(src_base) -I$(src_root)/libxsd $(obj) $(dep): $(xerces_c.l.cpp-options) genf := $(xsd:.xsd=.hxx) $(xsd:.xsd=.ixx) $(xsd:.xsd=.cxx) @@ -35,7 +34,7 @@ gen := $(addprefix $(out_base)/,$(genf)) $(gen): xsd := $(out_root)/xsd/xsd -$(gen): xsd_options := \ +$(gen): xsd_options += \ --type-naming knr \ --function-naming knr \ --generate-ostream \ @@ -45,7 +44,7 @@ $(gen): xsd_options := \ $(gen): $(out_root)/xsd/xsd -$(call include-dep,$(dep)) +$(call include-dep,$(dep),$(obj),$(gen)) # Convenience alias for default target. # @@ -82,7 +81,12 @@ endif $(call include,$(bld_root)/cxx/o-e.make) $(call include,$(bld_root)/cxx/cxx-o.make) $(call include,$(bld_root)/cxx/cxx-d.make) + +$(call include,$(bld_root)/cxx/standard.make) # cxx_standard +ifdef cxx_standard +$(gen): xsd_options += --std $(cxx_standard) $(call include,$(scf_root)/xsd/tree/xsd-cxx.make) +endif # Dependencies. -- cgit v1.2.3