Equation printing program

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Ganon11
    Recognized Expert Specialist
    • Oct 2006
    • 3651

    #61
    AGH!

    USE A DIFFERENT NAME FOR YOUR CHAR VARIABLE.

    Sorry, I can't believe no one's caught this yet. You can't use operator as the name of your char variable, because operator== is a function call for classes. Your compiler thinks you are calling the function operator== in every if statement, and then complains at the fact that there's no object, no parentheses, and no argument. Change the name to oper and see if it works.

    Comment

    • sicarie
      Recognized Expert Specialist
      • Nov 2006
      • 4677

      #62
      Originally posted by Ganon11
      AGH!

      USE A DIFFERENT NAME FOR YOUR CHAR VARIABLE.

      Sorry, I can't believe no one's caught this yet. You can't use operator as the name of your char variable, because operator== is a function call for classes. Your compiler thinks you are calling the function operator== in every if statement, and then complains at the fact that there's no object, no parentheses, and no argument. Change the name to oper and see if it works.
      It was caught (or at least different) in his other thread. There are three floating around now, I haven't gotten around to cleaning them all up.

      Comment

      • Ganon11
        Recognized Expert Specialist
        • Oct 2006
        • 3651

        #63
        I'm not sure if this is the 3rd or 4th time you've asked for help on this question, but before you proceed any further, could you take a good look at our Posting Guidelines, specifically the portion entitled Do Not Double Post your Questions.

        Comment

        • ilikepython
          Recognized Expert Contributor
          • Feb 2007
          • 844

          #64
          Originally posted by Ganon11
          AGH!

          USE A DIFFERENT NAME FOR YOUR CHAR VARIABLE.

          Sorry, I can't believe no one's caught this yet. You can't use operator as the name of your char variable, because operator== is a function call for classes. Your compiler thinks you are calling the function operator== in every if statement, and then complains at the fact that there's no object, no parentheses, and no argument. Change the name to oper and see if it works.
          Yes AGH!!!
          I thought about that the name might be the problem at least 5 times but I couldn't figure out why so I always ignored it.

          P.S. The O/P made it really confusing with double posting.

          Comment

          Working...