Skip to content

Commit

Permalink
Bug 1235261 - Part 6: Rename AutoInfallibleTArray to AutoTArray. r=fr…
Browse files Browse the repository at this point in the history
…oydnj
  • Loading branch information
poiru committed Feb 2, 2016
1 parent 62cff61 commit e00f212
Show file tree
Hide file tree
Showing 15 changed files with 26 additions and 26 deletions.
6 changes: 3 additions & 3 deletions dom/bluetooth/common/BluetoothService.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ GetAllBluetoothActors(InfallibleTArray<BluetoothParent*>& aActors)
contentIndex++) {
MOZ_ASSERT(contentActors[contentIndex]);

AutoInfallibleTArray<PBluetoothParent*, 5> bluetoothActors;
AutoTArray<PBluetoothParent*, 5> bluetoothActors;
contentActors[contentIndex]->ManagedPBluetoothParent(bluetoothActors);

for (uint32_t bluetoothIndex = 0;
Expand Down Expand Up @@ -487,7 +487,7 @@ BluetoothService::SetEnabled(bool aEnabled)
{
MOZ_ASSERT(NS_IsMainThread());

AutoInfallibleTArray<BluetoothParent*, 10> childActors;
AutoTArray<BluetoothParent*, 10> childActors;
GetAllBluetoothActors(childActors);

for (uint32_t index = 0; index < childActors.Length(); index++) {
Expand Down Expand Up @@ -571,7 +571,7 @@ BluetoothService::HandleShutdown()

Cleanup();

AutoInfallibleTArray<BluetoothParent*, 10> childActors;
AutoTArray<BluetoothParent*, 10> childActors;
GetAllBluetoothActors(childActors);

if (!childActors.IsEmpty()) {
Expand Down
12 changes: 6 additions & 6 deletions dom/ipc/TabParent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1497,9 +1497,9 @@ bool
TabParent::RecvRequestNativeKeyBindings(const WidgetKeyboardEvent& aEvent,
MaybeNativeKeyBinding* aBindings)
{
AutoInfallibleTArray<mozilla::CommandInt, 4> singleLine;
AutoInfallibleTArray<mozilla::CommandInt, 4> multiLine;
AutoInfallibleTArray<mozilla::CommandInt, 4> richText;
AutoTArray<mozilla::CommandInt, 4> singleLine;
AutoTArray<mozilla::CommandInt, 4> multiLine;
AutoTArray<mozilla::CommandInt, 4> richText;

*aBindings = mozilla::void_t();

Expand Down Expand Up @@ -1711,9 +1711,9 @@ bool TabParent::SendRealKeyEvent(WidgetKeyboardEvent& event)
if (event.mMessage == eKeyPress) {
nsCOMPtr<nsIWidget> widget = GetWidget();

AutoInfallibleTArray<mozilla::CommandInt, 4> singleLine;
AutoInfallibleTArray<mozilla::CommandInt, 4> multiLine;
AutoInfallibleTArray<mozilla::CommandInt, 4> richText;
AutoTArray<mozilla::CommandInt, 4> singleLine;
AutoTArray<mozilla::CommandInt, 4> multiLine;
AutoTArray<mozilla::CommandInt, 4> richText;

widget->ExecuteNativeKeyBinding(nsIWidget::NativeKeyBindingsForSingleLineEditor,
event, DoCommandCallback, &singleLine);
Expand Down
2 changes: 1 addition & 1 deletion dom/media/webspeech/synth/nsSynthVoiceRegistry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ GetAllSpeechSynthActors(InfallibleTArray<mozilla::dom::SpeechSynthesisParent*>&
++contentIndex) {
MOZ_ASSERT(contentActors[contentIndex]);

AutoInfallibleTArray<mozilla::dom::PSpeechSynthesisParent*, 5> speechsynthActors;
AutoTArray<mozilla::dom::PSpeechSynthesisParent*, 5> speechsynthActors;
contentActors[contentIndex]->ManagedPSpeechSynthesisParent(speechsynthActors);

for (uint32_t speechsynthIndex = 0;
Expand Down
2 changes: 1 addition & 1 deletion dom/plugins/ipc/PluginScriptableObjectChild.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ PluginScriptableObjectChild::ScriptableEnumerate(NPObject* aObject,
NS_ASSERTION(actor, "This shouldn't ever be null!");
NS_ASSERTION(actor->Type() == Proxy, "Bad type!");

AutoInfallibleTArray<PluginIdentifier, 10> identifiers;
AutoTArray<PluginIdentifier, 10> identifiers;
bool success;
actor->CallEnumerate(&identifiers, &success);

Expand Down
2 changes: 1 addition & 1 deletion dom/plugins/ipc/PluginScriptableObjectParent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ PluginScriptableObjectParent::ScriptableEnumerate(NPObject* aObject,
return false;
}

AutoInfallibleTArray<PluginIdentifier, 10> identifiers;
AutoTArray<PluginIdentifier, 10> identifiers;
bool success;
if (!actor->CallEnumerate(&identifiers, &success)) {
NS_WARNING("Failed to send message!");
Expand Down
2 changes: 1 addition & 1 deletion dom/xslt/xslt/txExecutionState.h
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ class txExecutionState : public txIMatchContext
RefPtr<txAExprResult> mGlobalVarPlaceholderValue;
int32_t mRecursionDepth;

AutoInfallibleTArray<TemplateRule, 10> mTemplateRules;
AutoTArray<TemplateRule, 10> mTemplateRules;

txIEvalContext* mEvalContext;
txIEvalContext* mInitialEvalContext;
Expand Down
4 changes: 2 additions & 2 deletions gfx/layers/client/ClientLayerManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "ClientReadbackLayer.h" // for ClientReadbackLayer
#include "nsAString.h"
#include "nsIWidgetListener.h"
#include "nsTArray.h" // for AutoInfallibleTArray
#include "nsTArray.h" // for AutoTArray
#include "nsXULAppAPI.h" // for XRE_GetProcessType, etc
#include "TiledLayerBuffer.h"
#include "mozilla/dom/WindowBinding.h" // for Overfill Callback
Expand Down Expand Up @@ -603,7 +603,7 @@ ClientLayerManager::ForwardTransaction(bool aScheduleComposite)

// forward this transaction's changeset to our LayerManagerComposite
bool sent;
AutoInfallibleTArray<EditReply, 10> replies;
AutoTArray<EditReply, 10> replies;
if (mForwarder->EndTransaction(&replies, mRegionToClear,
mLatestTransactionId, aScheduleComposite, mPaintSequenceNumber,
mIsRepeatTransaction, transactionStart, &sent)) {
Expand Down
6 changes: 3 additions & 3 deletions gfx/layers/ipc/ImageBridgeChild.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
#include "nsAutoPtr.h" // for nsRefPtr
#include "nsISupportsImpl.h" // for ImageContainer::AddRef, etc
#include "nsTArray.h" // for AutoTArray, nsTArray, etc
#include "nsTArrayForwardDeclare.h" // for AutoInfallibleTArray
#include "nsTArrayForwardDeclare.h" // for AutoTArray
#include "nsThreadUtils.h" // for NS_IsMainThread
#include "nsXULAppAPI.h" // for XRE_GetIOMessageLoop
#include "mozilla/StaticPtr.h" // for StaticRefPtr
Expand Down Expand Up @@ -654,7 +654,7 @@ ImageBridgeChild::EndTransaction()
return;
}

AutoInfallibleTArray<CompositableOperation, 10> cset;
AutoTArray<CompositableOperation, 10> cset;
cset.SetCapacity(mTxn->mOperations.size());
if (!mTxn->mOperations.empty()) {
cset.AppendElements(&mTxn->mOperations.front(), mTxn->mOperations.size());
Expand All @@ -664,7 +664,7 @@ ImageBridgeChild::EndTransaction()
ShadowLayerForwarder::PlatformSyncBeforeUpdate();
}

AutoInfallibleTArray<EditReply, 10> replies;
AutoTArray<EditReply, 10> replies;

if (mTxn->mSwapRequired) {
if (!SendUpdate(cset, mTxn->mDestroyedActors, &replies)) {
Expand Down
2 changes: 1 addition & 1 deletion gfx/layers/ipc/ShadowLayers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,7 @@ ShadowLayerForwarder::EndTransaction(InfallibleTArray<EditReply>* aReplies,
mTxn->AddEdit(OpSetLayerAttributes(nullptr, Shadow(shadow), attrs));
}

AutoInfallibleTArray<Edit, 10> cset;
AutoTArray<Edit, 10> cset;
size_t nCsets = mTxn->mCset.size() + mTxn->mPaints.size();
MOZ_ASSERT(nCsets > 0 || mTxn->RotationChanged(), "should have bailed by now");

Expand Down
2 changes: 1 addition & 1 deletion hal/WindowIdentifier.h
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ class WindowIdentifier
*/
uint64_t GetWindowID() const;

AutoInfallibleTArray<uint64_t, 3> mID;
AutoTArray<uint64_t, 3> mID;
nsCOMPtr<nsPIDOMWindowInner> mWindow;
bool mIsEmpty;
};
Expand Down
2 changes: 1 addition & 1 deletion hal/sandbox/SandboxHal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Vibrate(const nsTArray<uint32_t>& pattern, const WindowIdentifier &id)
{
HAL_LOG("Vibrate: Sending to parent process.");

AutoInfallibleTArray<uint32_t, 8> p(pattern);
AutoTArray<uint32_t, 8> p(pattern);

WindowIdentifier newID(id);
newID.AppendProcessID();
Expand Down
2 changes: 1 addition & 1 deletion js/xpconnect/src/xpcprivate.h
Original file line number Diff line number Diff line change
Expand Up @@ -2885,7 +2885,7 @@ class XPCJSContextStack
JSContext* Pop();
bool Push(JSContext* cx);

AutoInfallibleTArray<XPCJSContextInfo, 16> mStack;
AutoTArray<XPCJSContextInfo, 16> mStack;
XPCJSRuntime* mRuntime;
JSContext* mSafeJSContext;
};
Expand Down
2 changes: 1 addition & 1 deletion layout/generic/nsFontInflationData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ ComputeDescendantISize(const nsHTMLReflowState& aAncestorReflowState,
return aAncestorReflowState.ComputedISize();
}

AutoInfallibleTArray<nsIFrame*, 16> frames;
AutoTArray<nsIFrame*, 16> frames;
for (nsIFrame *f = aDescendantFrame; f != ancestorFrame;
f = f->GetParent()->FirstInFlow()) {
frames.AppendElement(f);
Expand Down
4 changes: 2 additions & 2 deletions layout/style/nsAnimationManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ nsAnimationManager::BuildAnimations(nsStyleContext* aStyleContext,
// the replacement on a per-property basis rather than a per-rule
// basis, just like everything else in CSS.

AutoInfallibleTArray<KeyframeData, 16> sortedKeyframes;
AutoTArray<KeyframeData, 16> sortedKeyframes;

for (uint32_t ruleIdx = 0, ruleEnd = rule->StyleRuleCount();
ruleIdx != ruleEnd; ++ruleIdx) {
Expand Down Expand Up @@ -690,7 +690,7 @@ nsAnimationManager::BuildAnimations(nsStyleContext* aStyleContext,
// means we need every keyframe with the property in it, except
// for those keyframes where a later keyframe with the *same key*
// also has the property.
AutoInfallibleTArray<uint32_t, 16> keyframesWithProperty;
AutoTArray<uint32_t, 16> keyframesWithProperty;
float lastKey = 100.0f; // an invalid key
for (uint32_t kfIdx = 0, kfEnd = sortedKeyframes.Length();
kfIdx != kfEnd; ++kfIdx) {
Expand Down
2 changes: 1 addition & 1 deletion layout/style/nsCSSParser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15162,7 +15162,7 @@ CSSParserImpl::ParseFunction(nsCSSKeyword aFunction,
* functions. The number 16 is coming from the number of arguments that
* matrix3d() accepts.
*/
AutoInfallibleTArray<nsCSSValue, 16> foundValues;
AutoTArray<nsCSSValue, 16> foundValues;
if (!ParseFunctionInternals(aAllowedTypes, aAllowedTypesAll, aMinElems,
aMaxElems, foundValues)) {
return false;
Expand Down

0 comments on commit e00f212

Please sign in to comment.