Граф коммитов

207 Коммитов

Автор SHA1 Сообщение Дата
Kartikaya Gupta 7906d74d42 Bug 1478097 - Follow-up to address review comments. r=me 2018-07-28 04:20:14 -04:00
Kartikaya Gupta 7d34b79e90 Bug 1478097 - Update indexer to visit implicit code inside constructors. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D2461

--HG--
extra : moz-landing-system : lando
2018-07-27 16:05:26 +00:00
Mike Hommey b2837054ff Bug 1469091 - Build the clang plugin as a host shared library. r=ted
This adds just enough host shared library support for this one use case,
but also takes shortcuts, because fully supporting host shared library
is a deep rabbit hole I'm not ready to take just to fix --enable-lto
--enable-clang-plugin on mac builds.

One downside is that one my machine the plugin now takes > 80s to build,
instead of 15s before, thanks to the lack of unified sources.

--HG--
extra : rebase_source : bf52a72a01d4e3eb77cf52b646b19734b9273075
2018-07-05 14:58:09 +09:00
Mike Hommey e22b35cf77 Bug 1470055 - Lift libstdc++ requirement relaxation when building clang-plugin. r=froydnj
--HG--
extra : rebase_source : 6c313ce673ff45fb1ca07530f801aef2f78be7e7
2018-06-21 11:45:30 +09:00
Mike Hommey 67a5371f47 Bug 1467658 - Upgrade the default clang toolchain to clang 6. r=chmanchester
The linux64-clang toolchain alias is currently clang 5. Switch it to
clang 6, but keep the spidermonkey tsan builds on clang 5 because of
bug 1467673.

The LLVM headers that come with clang 6 contain a DEBUG define that
conflicts with our DEBUG define and breaks the clang-plugin build,
so force unset ours.

--HG--
extra : rebase_source : aae88f1166108f003b06c022f14d5f4c61fc1ed9
2018-06-08 10:36:07 +09:00
Mike Hommey 27988b7ff9 Bug 1467658 - Allow the mozsearch-plugin code to build against clang 6. r=kats
Also work around https://bugs.llvm.org/show_bug.cgi?id=37746 by
explicitly handling ObjC interface variables separately. This actually
allows the searchfox macosx build to go much further than it used to (it
now fails during make package with apparently no output for rust code)

--HG--
extra : rebase_source : 354981ca9deebed5c60d3684f5c3abc554422393
2018-06-08 13:18:53 +09:00
Sylvestre Ledru dcfef841a7 bug 1463425 - Fix flake8/pep8 issue by hand in build/ r=gps
MozReview-Commit-ID: AZdcEWyVV6e

--HG--
extra : rebase_source : b1c45028c8d46be5ba590a27a2f9f20e248a26b1
2018-05-21 23:58:19 +02:00
Sylvestre Ledru 8cd16bb55b bug 1463425 - autopep8 on build/ r=gps
MozReview-Commit-ID: ETzx4HsjbEF

--HG--
extra : rebase_source : 7e27a4cfe2bb358d513a18a33c245bcc6d559c46
2018-05-21 23:56:34 +02:00
Andi-Bogdan Postelnicu c523c8faa9 Bug 1440886 - Implement a static analysis checker to detect usage of PR_LoadLibrary and LoadLibraryA/LoadLibraryExA/LoadLibrary/LoadLibraryEx. r=Nika
MozReview-Commit-ID: CUjfeBeOdsk

--HG--
extra : rebase_source : 633b900794cba24030c2b93d4d070d1447fff39b
2018-03-07 14:36:44 +02:00
Jeff Walden cba0aa5d89 Bug 1452754 - Add tests to TestMustReturnFromCaller.cpp that verify that RAII destruction after a must-return-after expression is permitted. r=mystor
--HG--
extra : rebase_source : 6ca1082b766393fa90f3631fd09a399e01c9e6e6
2018-04-09 12:56:37 -07:00
Kartikaya Gupta 904dd3f563 Bug 1449291 - Use the macro expansion location for all tokens. r=emilio
MozReview-Commit-ID: 8lbpGSt6z4p

--HG--
extra : rebase_source : 048e11795f755391eca15666651dfc883b5ad8d9
2018-04-04 08:53:16 -04:00
Nathan Froyd 864247e806 Bug 1448028 - use third-party path list for implicit constructor checks; r=andi
The check for whether an implicit constructor is in a third-party
directory currently has a homegrown list of directories to ignore.
Let's move this over to the (more complete!) list of third-party
directories maintained elsewhere.
2018-03-27 10:51:31 -04:00
Chris Manchester de12a7992b Bug 1429875 - Remove expandlibs and instead generate list files in the mozbuild backend. r=glandium
MozReview-Commit-ID: 5eLwnh1HHGj

--HG--
extra : rebase_source : cd308adc4542be0f9b33b64d31a2d0dc0310fcd4
2018-03-20 16:31:05 -07:00
Emilio Cobos Álvarez b4171daa96 Bug 1444416: Make the diagnostic point to the bogus argument. r=mystor
It's much easier to find that way, specially for functions with tons of
argument.

MozReview-Commit-ID: i3PMjDOcH7

--HG--
extra : rebase_source : 2c79f0b4eb5c6022c3896ded3bd26ceda524ce5a
2018-03-09 19:37:58 +01:00
Emilio Cobos Álvarez 2125f0fbd4 Bug 1444416: Handle references in the "can run script" checker. r=mystor
MozReview-Commit-ID: 8F9HjiFqbGN

--HG--
extra : rebase_source : 03d49b9a605ff5eade81a814b0903f81d87720ab
2018-03-09 17:51:59 +01:00
Andi-Bogdan Postelnicu 87f362c024 Bug 1443438 - Modify matcher isInSystemHeader to be polymorphic. r=mystor
MozReview-Commit-ID: sA4XmHMkaR

--HG--
extra : rebase_source : 76e33cfe1b1de1df5e2cfcc36160d04fec98fdfc
2018-03-06 11:59:05 +02:00
Kartikaya Gupta e9cad65dd5 Bug 1438866 - Mark empty filenames not interesting. r=emilio
In some cases we have SourceLocation objections that are isMacroId()
rather than isFileId() and so don't have a filename at all. In other
cases the filename is something clang-internal like "<scratch>". In
both of these situations we don't want to output any analysis data.
However, the code previously was taking the empty filename and resolving
it relative to the source folder, and then tried to write to the
source folder or create a file corresponding to a subfolder. This
resulted in general badness. This patch makes sure we ignore analysis
from places that don't have a corresponding file so that we don't
have this problem.

MozReview-Commit-ID: 7WluygY9Uy8

--HG--
extra : rebase_source : 35d7e71fc05bbd5a3357a57db9de25782178622a
2018-02-18 22:18:57 -05:00
Kartikaya Gupta 87bfbc06cf Bug 1438866 - Add some utility code to help with debugging. r=emilio
This adds an RAII class and macro that can be quickly added in functions
to log entry/exit from the function. This is useful to debugging.

MozReview-Commit-ID: 4Ud8jLOxI0R

--HG--
extra : rebase_source : 518d30fe44dff67bffb186e23c1eb858c02280af
2018-02-16 17:07:39 -05:00
Kartikaya Gupta 31c634d913 Bug 1438866 - Use proper path separators for windows. r=emilio
The indexer has paths handed to it on Windows with the backslash path separator.
However it currently hard-codes the forward-slash Unix/macOS path separator,
so we need to generify that code appropriately.

MozReview-Commit-ID: Iy8bImt2BXW

--HG--
extra : rebase_source : 4b88b44319c05ce816afc4e690d3d33d39b7e43c
2018-02-16 17:07:39 -05:00
Chris Peterson fe5cd3d5d9 Bug 1436263 - Part 3: Remove `virtual` from final virtual function declarations. r=froydnj
MozReview-Commit-ID: 8pjYjEvQF42

--HG--
extra : rebase_source : 5eb0bea2ef5f06a811b4f3daf57ce8720f12dd07
2018-02-08 21:22:43 -08:00
Chris Peterson d09123f248 Bug 1436263 - Part 1: Replace `final override` virtual function specifiers with just `final`. r=froydnj
MozReview-Commit-ID: DE5HkIhsZ6D

--HG--
extra : rebase_source : 94831c1e13a840dd2ea0600f64bcf70c2bf938d9
extra : source : cf9283bf1b0bca3a6311c98e227329d451f80ecb
2018-02-05 22:46:57 -08:00
Kartikaya Gupta fe694732ac Bug 1435345 - Part 1: Index use sites of overloaded C++ operators. r=emilio
MozReview-Commit-ID: 1nTIGliiQIz

--HG--
extra : rebase_source : 7ec5898035a19ee70409c15a24475d56a9c3bec6
2018-02-02 22:39:39 -05:00
Kartikaya Gupta e1d953260f Bug 1435345 - Part 0: sync change from searchfox repo. r=emilio
This change was made in the mozsearch/mozsearch repo at some point and wasn't
synced to m-c.

MozReview-Commit-ID: HnW80AIrGt7

--HG--
extra : rebase_source : f621d89cb712ac5c13e7636cf2d9d7222a6f422b
2018-02-02 22:39:24 -05:00
Eric Rahm f311645aa5 Bug 1434689 - Part 1: Add moz_temporary_class annotation. r=mystor
This adds a `moz_temporary_class` annotation that can be used to indicate
a class is intended to only be used as a temporary.

--HG--
extra : rebase_source : 2c4d5f0946739eafba485053624199bd4a05107a
2018-01-31 15:03:26 -08:00
Emilio Cobos Álvarez f8bf50c79e Bug 1434326: Cleanup DiagnosticsMatcher constructor. r=mystor
Removing a bit of the ugly :)

MozReview-Commit-ID: ATf2b2oh1F1

--HG--
extra : rebase_source : da6e36533c2b2ec8820c728953b0c0544c5a085e
2018-01-30 17:40:00 +01:00
Emilio Cobos Álvarez b012f3eebd Bug 1434001: Handle lambdas in CanRunScriptChecker. r=mystor
Such a shame that the functionDecl() matcher doesn't handle them. I didn't find
a cleaner way to handle them, but I'm a 100% noob with AST matchers, so there
may be a more elegant way to do this.

MozReview-Commit-ID: 3HJQdFpN4hy

--HG--
extra : rebase_source : 27e48e6fb264499fd99e75eb54a22276758ab3e4
2018-01-29 22:08:15 +01:00
Kartikaya Gupta 805ae43226 Bug 1430645 - Fix win64 compilation of mozsearch-plugin. r=emilio
MozReview-Commit-ID: 6xrnnZeYmFy

--HG--
extra : rebase_source : dd2e92b7179ac35baf5c39ecfb70952a21b87141
2018-01-15 14:33:04 -05:00
Chris Peterson 37efe4d0e6 Bug 1428535 - Add missing override specifiers to overridden virtual functions. r=froydnj
MozReview-Commit-ID: DCPTnyBooIe

--HG--
extra : rebase_source : cfec2d96faeb11656d86d760a34e0a04cacddb13
extra : intermediate-source : 6176724d63788b0fe8caa3f91607c2d93dbaa7ec
extra : source : eebbb0600447f9b64aae3bcd47b4be66c02a51ea
2017-11-05 19:37:28 -08:00
Emilio Cobos Álvarez 06f30cacd7 Bug 1428864: Fix indexer plugin build with clang >= 5. r=kats
MozReview-Commit-ID: J1DKFkyXu0v

--HG--
extra : rebase_source : 81d6abfa400c9c606d4bef5adc4633a831a713aa
2018-01-08 20:21:53 +01:00
Julian Hector 378f6d9cfb Bug 1398874 - Add static analysis to reject ParamTraits specializations for enum types. r=mystor 2017-12-05 10:26:41 -05:00
Kartikaya Gupta ef331d62ea Bug 1421768 - Fix overeager clang-tidy behaviour causing silent breakage in searchfox. r=me
This is an import of the change from https://github.com/mozsearch/mozsearch/pull/66
plus a correction in the README file. The change was reviewed in github.

MozReview-Commit-ID: A7gINlBubZ4
2017-11-30 16:52:51 -05:00
Nika Layzell a124bfae77 Bug 1418465 - Add an opt-out to the MOZ_CAN_RUN_SCRIPT analysis, r=andi
MozReview-Commit-ID: 2YKncUdrT5p
2017-11-24 11:15:17 -05:00
Kartikaya Gupta 4cf3084e60 Bug 1282172 - Detect enum constants generated by macros when generating the Searchfox index. r=billm
MozReview-Commit-ID: 5RUsVSMTU8

--HG--
extra : rebase_source : 32f803de363aaaaa8df9c3d0eac31653ecb3de48
2017-11-18 20:05:53 -05:00
Bill McCloskey dd8af9fa5c Bug 1418434 - Fix return value warning in clang plugin (r=mystor)
MozReview-Commit-ID: 3p7Vs4hZtoO
2017-11-18 15:41:06 -08:00
Bill McCloskey 794104b1e1 Bug 1413738 - Mozsearch clang plugin (r=mystor)
MozReview-Commit-ID: 53zUQ0vDMpd
2017-11-16 15:06:32 -08:00
André Bargull a83f81a2c5 Bug 1405993 - Part 1: Don't report warnings for sprintf calls in ICU. r=mystor
--HG--
extra : rebase_source : 2ad0906e64804f22615373f387d5db427aad8313
2017-11-01 11:47:59 -07:00
Chris Manchester 2a7d541658 Bug 1411712 - Move ldflags munging by the clang-plugin to moz.build r=mshal
MozReview-Commit-ID: JTZlXscUvlX

--HG--
extra : rebase_source : 96d7963429a362ac246b5ff93c828709168ef3cf
2017-11-02 11:47:48 -07:00
Chris Manchester d43c1ef2dd Bug 1403346 - Implement clang-plugin cxxflags in moz.build. r=glandium
MozReview-Commit-ID: 9zSryJcTRGl
2017-10-25 15:12:10 -07:00
Sylvestre Ledru 0d4a611a04 Bug 1410472 - clang-plugin follows the LLVM coding style for real r=mystor
MozReview-Commit-ID: AXrQEjWzxvg

--HG--
extra : rebase_source : bf972fbb22648af2edbb756eb899ebddf8444dbc
2017-10-20 19:11:50 +02:00
Chris Manchester fab07bc443 Bug 1386876 - Replace all uses of NO_VISIBILITY_FLAGS with a template and remove NO_VISIBILITY_FLAGS. r=glandium
MozReview-Commit-ID: 194U1WMCAM0

--HG--
extra : rebase_source : 365b68b0a1772d238ae9b84966e53dcd1197fd85
2017-05-01 18:12:35 -07:00
Chris Manchester c0a229d4c3 Bug 1386876 - Replace all uses of DISABLE_STL_WRAPPING with a template, remove DISABLE_STL_WRAPPING. r=glandium
MozReview-Commit-ID: FMEtb5PY7iP

--HG--
extra : rebase_source : 3cdee7528846462c758e623d6bcd2e6e17dbabff
2017-09-11 11:33:26 -07:00
Tristan Bourvon ba0998ae31 Bug 1380423 - Add static-analysis to enforce strict rules on functions which can run scripts. r=mystor
MozReview-Commit-ID: GGSyq0z5msB
2017-08-08 19:48:53 +03:00
Tristan Bourvon 5dba5275b8 Bug 1390064 - Fix IgnoreTrivials in Utils.h by changing cast to cast_or_null r=mystor
MozReview-Commit-ID: E1uMaMRrCuO

--HG--
extra : amend_source : 813d6f884ccb1736ee161d8cedce260a0a7a2a90
2017-08-14 11:40:36 +02:00
Tristan Bourvon cdc988e24a Bug 1374024 - apply clang-format on some files from static analysis. r=mystor
MozReview-Commit-ID: COh2u6PIeY
2017-07-13 12:00:06 +02:00
Tristan Bourvon 2e77c99160 Bug 1374024 - add checker to prevent dangling pointers returned by method calls on temporaries. r=mystor
MozReview-Commit-ID: 9khNt59ONF
2017-07-05 16:14:21 +02:00
Carsten "Tomcat" Book 6f930b42b1 Backed out changeset 1a0693cc418b (bug 1374024) for bustage 2017-07-13 15:14:51 +02:00
Carsten "Tomcat" Book 67bab57920 Backed out changeset b4a4d8144010 (bug 1374024) 2017-07-13 15:14:36 +02:00
Tristan Bourvon 8b77b81430 Bug 1374024 - clang-format on some files from static analysis directory. r=mystor
MozReview-Commit-ID: COh2u6PIeY
2017-07-12 14:32:09 +02:00
Tristan Bourvon 473b245885 Bug 1374024 - add checker to prevent dangling pointers returned by method calls on temporaries. r=mystor
MozReview-Commit-ID: 9khNt59ONFE
2017-07-05 16:14:21 +02:00
Carsten "Tomcat" Book 2332473008 Backed out changeset 1a49d403a9a4 (bug 1374024) for bustage 2017-07-13 11:10:31 +02:00