float_expr not supported by dump_expr .. (wha?)

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Martin Lepage

    float_expr not supported by dump_expr .. (wha?)

    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
  • Ron Natalie

    #2
    Re: float_expr not supported by dump_expr .. (wha?)


    "Martin Lepage" <zutroy@mad.sci entist.com> wrote in message news:gOXeb.9441 8$C92.37899@cha rlie.risq.qc.ca ...
    [color=blue]
    >
    > fonction(Data2D (0.2, 2.3));[/color]

    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.


    Comment

    • Martin Lepage

      #3
      Re: float_expr not supported by dump_expr .. (wha?)

      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 :)
      [color=blue]
      > "Martin Lepage" <zutroy@mad.sci entist.com> wrote in message
      > news:gOXeb.9441 8$C92.37899@cha rlie.risq.qc.ca ...
      >
      >[color=green]
      >> fonction(Data2D (0.2, 2.3));[/color]
      >
      > 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.[/color]

      Comment

      Working...