Only a couple of files really need to include this header now to use
ignore_result(), and we can just drop the include from everywhere else.
Chromium changes:
https://chromium.googlesource.com/chromium/src.git/+/2e6be1400ab678f21d871d0d3a1199912967324fhttps://chromium.googlesource.com/chromium/src.git/+/5666ff4f5077a7e2f72902f3a95f5d553ea0d88dhttps://chromium.googlesource.com/chromium/src.git/+/3a3f9436142e712d4a7e2a962d85154876fa395f
commit 2e6be1400ab678f21d871d0d3a1199912967324f
Author: Peter Boström <pbos@chromium.org>
Date: Sat Nov 13 01:28:25 2021 +0000
Rename "base/macros.h" => "base/ignore_result.h"
This file only contains ignore_result() and is no longer a collection of
macros.
This change fixes a couple of missing IWYU removals as well.
Bug: 1010217
commit 5666ff4f5077a7e2f72902f3a95f5d553ea0d88d
Author: Peter Boström <pbos@chromium.org>
Date: Fri Nov 12 03:40:24 2021 +0000
Remove most remaining unused "base/macros.h"
Removes `#include "base/macros.h"` from remaining .cc, .h and .mm files
that do not contain `ignore_result(` and do not trigger pre-commit or
pre-upload errors.
Bug: 1010217
commit 3a3f9436142e712d4a7e2a962d85154876fa395f
Author: Peter Boström <pbos@chromium.org>
Date: Mon Nov 8 21:04:37 2021 +0000
Add #include "base/macros.h" for ignore_result()
This fixes IWYU for existing instances of ignore_result() to make
removal of #include "base/macros.h" from files using it for DISALLOW_*
macros easier.
Bug: 1010217
Chromium change:
https://chromium.googlesource.com/chromium/src/+/39810e70da06baca176c0cdbc93164be1f980f59
commit 39810e70da06baca176c0cdbc93164be1f980f59
Author: Patrick Monette <pmonette@chromium.org>
Date: Thu Oct 14 18:06:59 2021 +0000
Reland "Move task-related files from base/ to base/task/"
This is a reland of 092c30c5fd4def5a0c63d6f3a8953bd07768dd44
The 2 problematic subrepos have been migrated and a couple late
addition of the old headers were migrated.
Original change's description:
> Move task-related files from base/ to base/task/
>
> The forward headers are updated to point to the new location, and the
> header guards were fixed.
>
> Bug: 1255932
Chromium change:
https://chromium.googlesource.com/chromium/src.git/+/1268a99
commit 1268a999c4a953d7e2b2c26bf9fa019e38ee0504
Author: Victor Costan <pwnall@chromium.org>
Date: Fri Jul 16 17:16:39 2021 +0000
sql: Change the Statement::ColumnBlob() return type to base::span.
ColumnBlob() currently returns a pointer to a data buffer, which must be
paired with the return result of ColumnByteLength(). This made sense
when the code was written, but we have safer and more ergonomic
alternatives now.
This CL switches the return type to base::span<const uint8_t>, which is
the closest reflection of the fact that BLOBs are arrays of bytes.
sql::Statement still has helpers for retrieving BLOB data as std::string
and std::vector<char> / std::vector<uint8_t>.
Bug: 1229451
The sql::Statement parameter passed to DecryptedCardFromColumn()
can't be const as the method will call ColumnByteLength() over it,
which is no longer declared a const method.
Chromium change:
https://chromium.googlesource.com/chromium/src/+/081d534f16b6b1523ca9a87a081285ab01d30265
commit 081d534f16b6b1523ca9a87a081285ab01d30265
Author: Victor Costan <pwnall@chromium.org>
Date: Thu Jul 15 14:23:59 2021 +0000
sql: Remove const qualifier from Statement::Column*() methods.
The sql::Statement::Column*() methods are currently const, which
suggests no internal state changes.
This is incorrect for the following reasons.
1. GetColumnType()'s comment indicates that Column*() perform SQLite
type conversion. So, the methods appear to change the underlying
SQLite state.
2. In general, the methods call into SQLite, and we can't guarantee that
SQLite state doesn't change.
This CL fixes the problem by removing the const qualifier from the
impacted methods.
Bug: 1229420
Chromium change:
https://source.chromium.org/chromium/chromium/src/+/2d59e682ab9eb904124f5778eb8ceb3cb2a90231
commit 2d59e682ab9eb904124f5778eb8ceb3cb2a90231
Author: Anton Bikineev <bikineev@chromium.org>
Date: Tue May 18 12:29:22 2021 +0000
Deprecate base/optional.h and fix remaining mentions.
Docs are still to be updated (in a followup).
Bug: 1202909
Converted remaining cases of base::Optional to absl::optional, plus
updated DEPS file with an exception that is temporarily required
while we don't have such exception added to Chromium's toplevel DEPS
file (see commit linked below, not yet included in 92.0.4503.5).
Chromium change:
https://source.chromium.org/chromium/chromium/src/+/9662571bb2954fb1759c49e5c45e59571cd1899e
commit 9662571bb2954fb1759c49e5c45e59571cd1899e
Author: Anton Bikineev <bikineev@chromium.org>
Date: Thu May 13 19:17:50 2021 +0000
Reland "Alias base::Optional to absl::optional"
This relands f3493eb4f80c5716ed2d7de195f710537beacc6b. The reason of the
failure: missing base// dep in some of the internal components, which
caused the branded builds to fail.
For sherrifs: the change may cause build failures on bots that are not
tested in the regular CQ pipeline. Those issues are mostly caused by
missing base// dependencies. Before reverting this change, please
consider fixing missing dependencies, similar to what the CL 2891488
does.
Original CL description:
> Alias base::Optional to absl::optional
>
> This CL does the following:
> 1) Replaces base::Optional and friends with aliases to corresponding
> entities from abseil. base::in_place is the only thing not aliased, as
> it's also used in other contexts (e.g. StructPtr in mojo).
> 2) Replaces all optional-related uses of base::in_place with
> absl::in_place.
> 3) Fixes missing headers (e.g. base/check.h) that used to be recursively
> included from base/optional.h
> 4) Also, removes forward declarations for base::Optional and instead
> includes "base/optional.h" directly. The argument is the same as for
> forward declarations of std types - the exact declaration (struct vs
> class, number of template arguments (e.g. for SFINAE)) is an
> implementation detail that can change.
>
> The CL also tries to support base/optional_unittest.cc (will be removed
> with base/optional.h) however the nocompile is already removed, since
> supporting it seems to be harder.
>
> Followup CLs will replace base::optional with absl::optional per
> component.
>
> Bug: 1202909
> Change-Id: I25b276401ceba13da35b3a0331d5ccbd338c4539
> AX-Relnotes: n/a.
> Reviewed-on:
> https://chromium-review.googlesource.com/c/chromium/src/+/2892208
> Commit-Queue: Anton Bikineev <bikineev@chromium.org>
> Commit-Queue: Peter Kasting <pkasting@chromium.org>
> Reviewed-by: Peter Kasting <pkasting@chromium.org>
> Reviewed-by: Kentaro Hara <haraken@chromium.org>
> Owners-Override: Peter Kasting <pkasting@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#882460}
Bug: 1202909
We need to use either u"..." literals or char16_t constant strings now.
Chromium changes:
https://chromium.googlesource.com/chromium/src.git/+/522370fb5f2b8ec0719a3752bcac4897164dd32d
commit 522370fb5f2b8ec0719a3752bcac4897164dd32d
Author: Jan Wilken Dörrie <jdoerrie@chromium.org>
Date: Fri Apr 16 17:22:39 2021 +0000
[LSC] Disallow base::ASCIIToUTF16("...") outside of tests
This change modifies base::ASCIIToUTF16 to cause compilation errors when
it is used with a string constant outside of tests. Instead, callers
should just use a UTF16 literal (u"...") instead.
Bug: 1189439
https://chromium.googlesource.com/chromium/src.git/+/7e1e44476bb361e95dc252d8428324a3feb89ecd
commit 7e1e44476bb361e95dc252d8428324a3feb89ecd
Author: Jan Wilken Dörrie <jdoerrie@chromium.org>
Date: Sun Mar 14 19:37:05 2021 +0000
[LSC] Remove base/strings/string16.h
This change removes base/strings/string16.h and remaining references to
it from the code base.
Bug: 1184339
commit 9ca8a38a28e547d0c47630e3e56a69d06c7ab68b
Author: Peter Kasting <pkasting@chromium.org>
Date: Wed May 12 03:08:22 2021 +0000
Ban UTF8ToUTF16 on compile-time string constants.
Bug: 1189439
The "base/strings/string16.h" file does no longer exist and we need
to remove all remaining usages of that type with the one from the
C++ standard library instead, like Chromium upstream already did.
Also replaces no longer needed ASCIIToUTF16 and UTF8ToUTF16 calls used
with constant strings with `u` string literals.
Chromium change:
https://chromium.googlesource.com/chromium/src.git/+/7e1e44476bb361e95dc252d8428324a3feb89ecd
commit 7e1e44476bb361e95dc252d8428324a3feb89ecd
Author: Jan Wilken Dörrie <jdoerrie@chromium.org>
Date: Sun Mar 14 19:37:05 2021 +0000
[LSC] Remove base/strings/string16.h
This change removes base/strings/string16.h and remaining references to
it from the code base.
Bug: 1184339
We had made services.cc depend on //brave/utility via a chromium_src
override, but that caused a dependency cycle because //brave/utility
also depends on //chrome/utility (e.g. extend some upstream classes),
causing a gn check error.
To fix this, we can follow the pattern used in other places and make
upstream's //chrome/utility directly include the files from Brave that
it needs, and replace the oneliner patch to //chrome/utility/BUILD.gn
with one that would simply include those sources, instead of having it
depend on //brave/utility.
Last, we also add a missing dep on //brave/common/importer:importer
to avoid another gn check failure due to having some files from that
target included from brave_external_process_importer_bridge.h.
Resolves https://github.com/brave/brave-browser/issues/10623
Chromium change:
https://source.chromium.org/chromium/chromium/src/+/c01e115c2633e007d23be7ecc69c092b1cc7a933
commit c01e115c2633e007d23be7ecc69c092b1cc7a933
Author: Jan Wilken Dörrie <jdoerrie@chromium.org>
Date: Thu Dec 10 15:51:48 2020 +0000
[Passwords] Replace Blacklist with Blocklist in PasswordStore and others
This change replaces usages of Blacklist with Blocklist in the
PasswordStore, LoginDatabase and fixes comments that were missed in
other places. Note that this change does not yet rename the actual SQL
columns in the Login Data database.
Bug: 1147799
Chromium changes:
https://chromium.googlesource.com/chromium/src.git/+/3bbb69a821f89abf22beab20b1eabc015a71d8ab
commit 3bbb69a821f89abf22beab20b1eabc015a71d8ab
Author: Jan Wilken Dörrie <jdoerrie@chromium.org>
Date: Tue Nov 3 06:59:57 2020 +0000
[Passwords] Remove autofill::PasswordForm from //chrome/*/importer
This change replaces most usage of autofill::PasswordForm in the
importer code and uses a new importer::ImportedPasswordForm struct
instead.
This is necessary, because PasswordForm is being moved to the //browser
component, and thus is no longer accessible from other components like
//common or //utility.
Bug: 1067347
https://chromium.googlesource.com/chromium/src.git/+/9c84018d43d95b8c7ca850653af9452b4edc895b
commit 9c84018d43d95b8c7ca850653af9452b4edc895b
Author: Jan Wilken Dörrie <jdoerrie@chromium.org>
Date: Tue Nov 3 09:57:10 2020 +0000
[Passwords] Move password_form.h to //components/password_manager
This change moves password_form.h and password_form.cc from
/autofill/core/common to /password_manager/core/browser and fixes
remaining compilation issues.
Bug: 1067347
Without this, will get build error like:
In file included from
/brave/src/brave/chromium_src/chrome/utility/services.cc:32:
../../brave/components/services/bat_ads/bat_ads_service_impl.h:13:10:
fatal error: 'bat/ads/ads.h' file not found
This means renaming uses of ServiceBinding to ServiceReceiver, as
well as removing any use of the old InterfaceRequest<T> type (e.g.
used by the ServiceRequest alias) and use PendinReceiver<T> instead.
Chromium change:
https://chromium.googlesource.com/chromium/src/+/bb551f12072ebf7a9af6df26a51d125f90078453
commit bb551f12072ebf7a9af6df26a51d125f90078453
Author: Gyuyoung Kim <gyuyoung@igalia.com>
Date: Thu Jul 2 00:12:00 2020 +0000
Convert mojom::ServiceRequest to PendingReceiver<mojom::Service>
There are many uses of mojom::ServiceRequest. This CL migrates
them to PendingReceiver<mojom::Service>.
Besides that, ServiceBinding is renamed to ServiceReceiver and
the variable name is also changed from |binding_| to |receiver_|
or |service_binding_| to |service_receiver_|.
Bug: 955171
ChromeImporter runs in a separated service from upstream import service.
This new import service will use chrome::mojom::ProfileImportObserver and
brave::mojom::ProfileImportObserver and they are passed via
brave::mojom::ProfileImport.
brave::mojom::ProfileImportObserver and BraveImportBridge only define additional
interface.
With this warning dialog, user will close chrome windows.
After that user clicks continue button, browser will not check lock again aind
will try to import chrome's settings.
Even if chrome is still running, importing will be done because
importing is done with temporarily copied db files.
BraveExternalProcessImporterHost will fetch available extensions list
and ask to install them.
Other importing options are done via other utility process but
importing extension should be done in browser process.
So, BraveExternalProcessImporterHost manages extension installs.
BraveExternalProcessImporterHost will fetch available extensions list
and ask to install them.
Other importing options are done via other utility process but
importing extension should be done in browser process.
So, BraveExternalProcessImporterHost manages extension installs.
NOTE: this commits has many cleanup changes around importing area
that uses deprecated patching style.
fix https://github.com/brave/brave-browser/issues/7974
Chromium change:
https://chromium.googlesource.com/chromium/src/+/f070ffde7ce159aa8687e850b95c2a54f8caf5d3
commit f070ffde7ce159aa8687e850b95c2a54f8caf5d3
Author: Joshua Bell <jsbell@chromium.org>
Date: Tue Dec 10 19:44:51 2019 +0000
SQL: Disallow implicit integer downconversion on BindInt
Calling sql::Statement::BindInt() with an int64_t argument silently
downconverted, potentially saving incorrect data to a database.
sql::Statement::BindInt64(int64_t) should be used instead.
Introduce an uncallable sql::Statement::BindInt(int64_t) overload to
fail the compile. This also catches calling BindInt with uint32_t. Fix
up various callers that were silently downconverting.
Bug: 908690
Since the V11 cookies db schema, firstpartyonly column is renamed to samesite.
Also, BraveImporter and ChromeImporter should have different cookies query
string because muon uses old schema.
Chromium changes:
https://chromium.googlesource.com/chromium/src/+/0b653a39fe832ec8366948cc343f2b5a97ab57fa
commit 0b653a39fe832ec8366948cc343f2b5a97ab57fa
Author: Marc Treib <treib@chromium.org>
Date: Tue Sep 3 11:00:37 2019 +0000
Clear the account-scoped PasswordStore on signout
This adds an "is_account_store" flag to LoginDatabase, which specifies
whether this DB stores profile-scoped or Gaia-account-scoped data.
Sync uses this flag to clear the account-scoped data on signout.
In the future, the flag will also be used by the DB itself to "tag"
credentials it returns as coming from the account or from the profile.
Bug: 998455
https://chromium.googlesource.com/chromium/src/+/00380bfbde67971670a4e4afcaa513622905d8a5
commit 00380bfbde67971670a4e4afcaa513622905d8a5
Author: Marc Treib <treib@chromium.org>
Date: Wed Sep 4 08:04:37 2019 +0000
LoginDatabase: Use a strong alias for is_account_store param
With this change, callers have to write
new LoginDatabase(path, IsAccountStore(true))
instead of
new LoginDatabase(path, /*is_account_store=*/true)
which is clearer (no way to forget the comment), especially if any
other (boolean) parameters are added at any later point.
Bug: 998455