https://bugs.documentfoundation.org/show_bug.cgi?id=148415

            Bug ID: 148415
           Summary: More detailed, better explained loplugin errors
           Product: LibreOffice
           Version: 7.4.0.0 alpha0+ Master
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: framework
          Assignee: libreoffice-bugs@lists.freedesktop.org
          Reporter: kelem...@ubuntu.com
                CC: hoss...@libreoffice.org,
                    ilmari.lauhakan...@libreoffice.org,
                    noelgran...@gmail.com, sberg...@redhat.com,
                    t...@libreoffice.org

This is not about LO, but about the clang plugins used by Jenkins.

In many cases the plugins end up giving error messages on a patch, which may be
difficult to understand for beginner programmers - or even more experienced
ones who do not follow new developments in the clang plugins area.

It came up that it would be better/more educative if ALL these error
messages[1] were all uniformly a bit more explanatory:
- Why is some practice considered "wrong"? This may be dug out of git logs, but
that's  super inconvenient.
- What should I change to do it correctly, possibly with an example.

Adding experienced devs and TDF mentors to CC. It would be beneficial to review
all the plugins and change their error messages to be very descriptive if they
are currently not.

[1] Just for examples from builds on top of the list:
https://gerrit.libreoffice.org/c/core/+/132571 writes:
clang plugin redundantcast did trigger. redundant static_cast from
"SwParaPortion *" to "SwLinePortion *"
- tells why is this bad, but no explanation on what to do (might be seen as
trivial... but that's just an assumption of experienced devs, better to make
sure ;) )

https://gerrit.libreoffice.org/c/core/+/130692 writes:
clang plugin fakebool did trigger. use "true" instead of "sal_True" 
- no explanation why is this bad, but tells what to change

https://gerrit.libreoffice.org/c/core/+/132505 writes:
clang plugin stringviewparam did trigger. replace function parameter of type
"const rtl::OUString &" with "std::u16string_view"
- no explanation why is this bad, but tells what to change

clang plugin simplifyconstruct did trigger. no need to explicitly init an
instance of "::std::unique_ptr<FileChangedChecker>" with nullptr, just use
default constructor
- explains why is this bad and what to do instead - excellent!

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to