Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Create implementation sometimes adds class to rval

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
tjcbs Posted - Sep 15 2016 : 06:05:43 AM
Sometimes, but not always, Create implementation adds the class name to the return value, like this.

mat4::mat4& mat4::setPos(const vec3& pos)
{

}


Notice the "mat4::" prepended to the return value.

I don't know why this is happening for this class, but not others. The class is below:


struct mat4
{
   mat4();
   mat4(    float cxrx, float cxry, float cxrz, float cxrw,
            float cyrx, float cyry, float cyrz, float cyrw,
            float czrx, float czry, float czrz, float czrw,
            float cwrx, float cwry, float cwrz, float cwrw); 
   
   void set(float cxrx, float cxry, float cxrz, float cxrw,
            float cyrx, float cyry, float cyrz, float cyrw,
            float czrx, float czry, float czrz, float czrw,
            float cwrx, float cwry, float cwrz, float cwrw); 

   mat4& identity();
   mat4& transform(const vec3& pos);
   mat4& setPos(const vec3& pos);
   mat4& lookAt(const vec4& eye, const vec4& target, const vec4& up);
   mat4& perspective(float fovY, float aspect, float zNear, float zFar);
   mat4& rotate(float rad, const vec3& axis);
   mat4& rotateAbout(float rad, const vec3& axis, const vec3& pos = vec3(0.f));
   mat4&  operator *=(const mat4& n);
   mat4  operator *(const mat4& n);
   vec4  operator *(const vec4& u);
   operator float*();
   operator const float*() const;


   vec4 x, y, z, w;
};


If need be I can send the referenced header files.
3   L A T E S T    R E P L I E S    (Newest First)
accord Posted - Sep 19 2016 : 7:24:29 PM
Did you try to reproduce this in your "real" project which you are working with?

Can you please try creating a clean new C++ console project, paste the code and try reproducing this problem there? I am wondering if your code has something that causes this OR if some setting or other environmental factor is playing a role here.
tjcbs Posted - Sep 16 2016 : 08:46:48 AM
No, it only shows symbols related to this class, even without the checkbox ticked.
accord Posted - Sep 15 2016 : 7:17:45 PM
I cannot reproduce the problem using your sample code.

Do you have a namespace named mat4?

If you open Find Symbol Dialog (alt+shift+s) and type .mat4. what results do you get? Do you only get results related to this very class? What if you untick the checkbox named "Show only symbols defined in current solution"? Does it make any different in this regard?

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000