Wow, wow, wow,
Guys, this was my private program. I simply did not have access to the
I see the mailing program did not attach the code.
Here it is:
#pragma once
#include <string>
#include <fstream>
class CFXTrade
{
public:
CFXTrade();
CFXTrade(int, const std::string&, double);
virtual ~CFXTrade();
public:
int m_TradeID;
std::string m_Name;
double m_Amount;
public:
// Write the attributes to file
void getWrittenToDisk(std::ofstream&);
};
#include ".\fxtrade.h"
#include <cmath>
using namespace std;
CFXTrade::CFXTrade()
{
}
CFXTrade::CFXTrade(int nTradeID, const std::string& nName, double
nAmount)
: m_TradeID(nTradeID), m_Name(nName), m_Amount(nAmount) {}
CFXTrade::~CFXTrade() {}
// Write the attributes to file
void CFXTrade::getWrittenToDisk(ofstream& nOutput)
{
nOutput << m_TradeID << ";" << m_Name << ";" << m_Amount <<
endl;
}
#include "FXTrade.h"
#include <string>
#include <sstream>
#include <vector>
#include <queue>
#include <vector>
#include <iostream>
#include <cmath>
#include <exception>
#include As you have probably seen the issue was not with the CFXTrade class
but rather with the vectro<T> one. I very much doubt that there's a bug in the std::vector implementation
you're using. More likely CFXTrade doesn't meet the requirements for
vector element types (CopyConstructible and Assignable). But and queue
uses deque by default, and deque imposes the same requirements, so even
if your program works on your current compiler it could break if you use
any other compiler, or a different version, or even different options.
Of course, we can't really tell if you don't post the missing code.
Ben.
_______________________________________________
Boost-users mailing list
Boost-users@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users
--------------------------------------------------------
If you are not an intended recipient of this e-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute it. Click here for important additional terms relating to this e-mail. http://www.ml.com/email_terms/
--------------------------------------------------------
participants (1)
-
Sliwa, Przemyslaw (London)