gecko-dev/layout
Nicholas Nethercote 742fc7eb48 Bug 1297961 (part 1) - Introduce nsURI::GetSpecOrDefault(). r=hurley.
This function is an infallible alternative to nsIURI::GetSpec(). It's useful
when it's appropriate to handle a GetSpec() failure with a failure string, e.g.
for log/warning/error messages. It allows code like this:

  nsAutoCString spec;
  uri->GetSpec(spec);
  printf("uri: %s", spec.get());

to be changed to this:

  printf("uri: %s", uri->GetSpecOrDefault().get());

This introduces a slight behavioural change. Previously, if GetSpec() failed,
an empty string would be used here. Now, "[nsIURI::GetSpec failed]" will be
produced instead. In most cases this failure string will make for a clearer
log/warning/error message than the empty string.
* * *
Bug 1297961 (part 1b) - More GetSpecOrDefault() additions. r=hurley.

I will fold this into part 1 before landing.

--HG--
extra : rebase_source : ddc19a5624354ac098be019ca13cc24b99b80ddc
2016-08-26 16:02:31 +10:00
..
base Bug 1297961 (part 1) - Introduce nsURI::GetSpecOrDefault(). r=hurley. 2016-08-26 16:02:31 +10:00
build Bug 1296579 - Remove the SimplePush API r=kitcambridge,baku 2016-09-01 20:17:03 +02:00
doc Bug 906116 - part3.3: Replace NS_STYLE_HINT_FRAMECHANGE with nsChangeHint_ReconstructFrame. r=dbaron 2016-07-06 13:06:14 +08:00
forms Backed out changeset 75b2b455ddb1 (bug 1275493) for a11y selection failures e.g. in test_focus_selects.html. r=backout 2016-09-01 17:10:08 +02:00
generic Bug 1299066: Make NS_STYLE_DISPLAY_* an enum class. Prefer indexing instead of linear search in the frame constructor r=heycam,bz 2016-09-01 20:41:17 -07:00
inspector Bug 1296509 - Optimize GetFlattenedTreeParent. r=smaug 2016-08-19 14:43:53 -07:00
ipc Backed out changeset 9fa5ccaa8c6c (bug 1289650) 2016-08-24 23:15:49 +02:00
mathml Bug 1299066: Make NS_STYLE_DISPLAY_* an enum class. Prefer indexing instead of linear search in the frame constructor r=heycam,bz 2016-09-01 20:41:17 -07:00
media Bug 1286877 - do not set c-basic-offset for python-mode; r=gps 2016-07-14 10:16:42 -06:00
printing Bug 1297276 - Rename mfbt/unused.h to mfbt/Unused.h for consistency. r=froydnj 2016-08-24 14:47:04 +08:00
reftests Bug 1171419 part 11 - Reftests for grid/flex list-item numbering. 2016-09-01 17:36:23 +02:00
style Bug 1297961 (part 1) - Introduce nsURI::GetSpecOrDefault(). r=hurley. 2016-08-26 16:02:31 +10:00
svg Merge inbound to m-c. a=merge 2016-08-31 22:33:17 -04:00
tables Bug 1299066: Make NS_STYLE_DISPLAY_* an enum class. Prefer indexing instead of linear search in the frame constructor r=heycam,bz 2016-09-01 20:41:17 -07:00
tools Bug 1299204 - Do GC and CC even more aggressively in reftests; r=mchang 2016-08-30 09:28:07 -07:00
xul Bug 1299066: Make NS_STYLE_DISPLAY_* an enum class. Prefer indexing instead of linear search in the frame constructor r=heycam,bz 2016-09-01 20:41:17 -07:00
moz.build Bug 1286877 - do not set c-basic-offset for python-mode; r=gps 2016-07-14 10:16:42 -06:00