From 07d270c87e6f9184aea4ca17eb26e466712e8db2 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sat, 22 Jun 2013 01:10:38 +0900 Subject: Require -std=c++11 and use std::shared_ptr instead of SharedHandle --- src/ValueBaseStructParserStateMachine.h | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/ValueBaseStructParserStateMachine.h') diff --git a/src/ValueBaseStructParserStateMachine.h b/src/ValueBaseStructParserStateMachine.h index 5b5efa56..a0f0e6a5 100644 --- a/src/ValueBaseStructParserStateMachine.h +++ b/src/ValueBaseStructParserStateMachine.h @@ -39,8 +39,7 @@ #include #include - -#include "SharedHandle.h" +#include namespace aria2 { @@ -56,8 +55,8 @@ class ValueBaseStructParserState; // value holder. class ValueBaseStructParserStateMachine : public StructParserStateMachine { public: - typedef SharedHandle ResultType; - static const SharedHandle& noResult(); + typedef std::shared_ptr ResultType; + static const std::shared_ptr& noResult(); struct NumberData { int64_t number; @@ -81,7 +80,7 @@ public: virtual void numberCallback(int64_t number, int frac, int exp); virtual void boolCallback(bool bval); - SharedHandle getResult() const; + std::shared_ptr getResult() const; virtual void reset(); @@ -92,8 +91,8 @@ public: void popArrayFrame(); void popDictFrame(); void pushFrame(); - void setCurrentFrameValue(const SharedHandle& value); - const SharedHandle& getCurrentFrameValue() const; + void setCurrentFrameValue(const std::shared_ptr& value); + const std::shared_ptr& getCurrentFrameValue() const; void setCurrentFrameName(const std::string& name); void pushDictState(); -- cgit