Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(186)

Issue 1845363003: String replaceWithLiteral should just use strlen, also rename to replace. (Closed)

Created:
4 years, 8 months ago by esprehn
Modified:
4 years, 8 months ago
CC:
blink-reviews, blink-reviews-dom_chromium.org, blink-reviews-layout_chromium.org, blink-reviews-style_chromium.org, blink-reviews-wtf_chromium.org, chromium-reviews, dglazkov+blink, eae+blinkwatch, gavinp+loader_chromium.org, Nate Chapin, jchaffraix+rendering, kinuko+watch, leviw+renderwatch, loading-reviews_chromium.org, Mikhail, pdr+renderingwatchlist_chromium.org, rwlbuis, sof, szager+layoutwatch_chromium.org, tyoshino+watch_chromium.org, zoltan1
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

String replaceWithLiteral should just use strlen, also rename to replace. The compiler will turn strlen on a literal into an integer, we don't need to use template magic for it. This also allows replace('x', kConstant) where kConstant is a literal string to get optimized by the compiler. Previously you'd need to call replace(UChar a, const String& b) which did a String allocation on the kConstant to execute the replace. Committed: https://crrev.com/ff8330c67efc3469abb1d83dc5bf5bb59bbaed97 Cr-Commit-Position: refs/heads/master@{#384513}

Patch Set 1 #

Patch Set 2 : remove cast. #

Patch Set 3 : Fix NUL insertion in foldQuoteMarksAndSoftHyphens. #

Patch Set 4 : Another NUL fix. #

Messages

Total messages: 27 (13 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1845363003/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1845363003/1
4 years, 8 months ago (2016-03-31 18:36:30 UTC) #3
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1845363003/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1845363003/20001
4 years, 8 months ago (2016-03-31 18:40:32 UTC) #6
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_compile_dbg_32_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_compile_dbg_32_ng/builds/180088)
4 years, 8 months ago (2016-03-31 18:58:33 UTC) #8
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1845363003/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1845363003/40001
4 years, 8 months ago (2016-03-31 21:47:00 UTC) #10
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: android_compile_dbg on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_compile_dbg/builds/43441) chromeos_amd64-generic_chromium_compile_only_ng on ...
4 years, 8 months ago (2016-03-31 22:02:01 UTC) #12
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1845363003/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1845363003/60001
4 years, 8 months ago (2016-04-01 00:09:58 UTC) #14
esprehn
4 years, 8 months ago (2016-04-01 04:39:58 UTC) #16
haraken
LGTM
4 years, 8 months ago (2016-04-01 04:41:18 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1845363003/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1845363003/60001
4 years, 8 months ago (2016-04-01 04:51:43 UTC) #19
Yuta Kitamura
lgtm
4 years, 8 months ago (2016-04-01 05:48:00 UTC) #20
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_TIMED_OUT, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/203569)
4 years, 8 months ago (2016-04-01 06:11:59 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1845363003/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1845363003/60001
4 years, 8 months ago (2016-04-01 07:05:42 UTC) #24
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 8 months ago (2016-04-01 07:58:39 UTC) #25
commit-bot: I haz the power
4 years, 8 months ago (2016-04-01 08:00:02 UTC) #27
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/ff8330c67efc3469abb1d83dc5bf5bb59bbaed97
Cr-Commit-Position: refs/heads/master@{#384513}

Powered by Google App Engine
This is Rietveld 408576698