float_expr not supported by dump_expr .. (wha?)

M

Martin Lepage

Hi World!

I have a general function that takes a (vector<double> &) as parameter.In
the case were I only need 2D vectors, I made the following class :

class Data2D : public vector<double> {
public:
Data2D(double x, double y) {
push_back(x); push_back(y);
}
};

Using this, I though I could use my original fonction in the following
way:

fonction(Data2D(0.2, 2.3));

But when I compile using gcc version 2.96 20000731 (Red Hat Linux 7.3
2.96-110) (I wish I could update my PC at work!) I get the following
message :

sorry, not implemented: 'float_expr' not supported by 'dump_expr'

I solved the problem by taking a copy of the vector (vector<double>)
instead in my original fonction. Can anyone tell me what I'm doing wrong?
Is it that I should never pass the reference of a temporary variable? I
only did so to avoid copying the vector to the fonction (thus saving a
little memory, I hope).

Thanks.

Martin Lepage
 
R

Ron Natalie

Martin Lepage said:
fonction(Data2D(0.2, 2.3));

What is the declaration of this function?
It's almost always a good idea to provide a complete minimal program
that demonstrates your problem when asking these questions.
 
M

Martin Lepage

On Thu, 02 Oct 2003 11:53:21 -0400, Ron Natalie wrote:

Thanks for your info and for the quick reply. I have tried to reproduce
the problem in a simple short program to post here but I am unable to get
the same weird error message. If I ever do, I'll post it here :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,143
Messages
2,570,822
Members
47,368
Latest member
michaelsmithh

Latest Threads

Top