-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Forward declaration of function masks errors in class #68
Comments
dude the variable naming inside the class should be as member variable i.e. m_bool .. something like that .. m_ as prefix for variables. |
Good catch! Forward declaration of classes hide errors in those classes.
S
…---
Sent via phone.
On Thu, May 18, 2017, 10:42 AM Max Smolens ***@***.***> wrote:
With KWStyle.xml:
<?xml version="1.0" encoding="iso-8859-1"?>
<Description>
<InternalVariables>m_[A-Z],0,1</InternalVariables>
</Description>
and Test.h:
#ifndef Test_h
#define Test_h
// Forward declaration
bool runTest();
class Test
{
public:
Test() {}
protected:
bool result;
};
#endif
KWStyle fails to show the error in the name of the member variable.
Without the forward declaration the error is detected correctly:
$ KWStyle -xml KWStyle.xml -v Test.h -gcc
Test.h:0: error: Internal variable (result) doesn't match regular expression (m_[A-Z])
The forward declaration shouldn't mask errors in the class below.
Tested with e03980f
<e03980f>
.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#68>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAREr5ZYXmYASibBXjFjvhxof7CG7BJ0ks5r7FjygaJpZM4NfVr0>
.
|
please close the issue if possible. many thnaks |
Has this bug been fixed? If so, what is the pull request # and merge?
s
…On Mon, Feb 24, 2020 at 2:47 AM Muhammad Wasim Akhtar Khan < ***@***.***> wrote:
please close the issue if possible. many thnaks
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#68?email_source=notifications&email_token=AACEJL43T4N746RZQ6B4HF3REN3STA5CNFSM4DL5LL2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEMW33EA#issuecomment-590200208>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AACEJL4GXWD3R3TG3OMQK33REN3STANCNFSM4DL5LL2A>
.
--
Stephen R. Aylward, Ph.D.
Senior Director of Strategic Initiatives
---
Kitware: *Advancing the frontiers of understanding*
*by developing innovative open-source software platforms*
*and integrating them into research, processes, and products.*
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
With
KWStyle.xml
:and
Test.h
:KWStyle fails to show the error in the name of the member variable.
Without the forward declaration the error is detected correctly:
The forward declaration shouldn't mask errors in the class below.
Tested with e03980f.
The text was updated successfully, but these errors were encountered: