[ create a new paste ] login | about

Link: http://codepad.org/E30yRqTU    [ raw code | fork ]

C++, pasted on Jun 14:
1
2
3
4
5
6
7
8
9
10
11
12
	class Data{
		public:
			std::string str;
			double var;

			template <typename UserType>
			UserType operator()() const { return  (UserType)var;}

			template <typename UserType>
			void operator()(UserType& utype) { var = utype; }

	};


Create a new paste based on this one


Comments: