From cdb4c44d6a5930414a854dcc22d607bb8d99ec89 Mon Sep 17 00:00:00 2001 From: Jeremy Siek Date: Tue, 24 Apr 2001 03:21:34 +0000 Subject: [PATCH] some VC++ workarounds [SVN r9966] --- include/boost/graph/graph_archetypes.hpp | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/include/boost/graph/graph_archetypes.hpp b/include/boost/graph/graph_archetypes.hpp index c9424d7f..48b45160 100644 --- a/include/boost/graph/graph_archetypes.hpp +++ b/include/boost/graph/graph_archetypes.hpp @@ -201,13 +201,15 @@ namespace boost { // should use a different namespace for this template typename property_map, P>::type get(P, property_graph_archetype&) { - return typename property_map, P>::type(); + typename property_map, P>::type pmap; + return pmap; } template typename property_map, P>::const_type get(P, const property_graph_archetype&) { - return typename property_map, P>::const_type(); + typename property_map, P>::const_type pmap; + return pmap; } template @@ -247,14 +249,10 @@ namespace boost { // should use a different namespace for this public: void push(const T&) {} void pop() {} - T& top() { return s_top; } - const T& top() const { return s_top; } + T& top() { return static_object::get(); } + const T& top() const { return static_object::get(); } bool empty() const { return true; } - private: - static T s_top; }; - template - T buffer_archetype::s_top(dummy_cons); } // namespace boost