Remove static constructors. GetScratchString was no longer used and GetTempStack was used too rarely to be a real performance benefit. r=harishd@netscape.com sr=waterson@netscape.com b=63014

git-svn-id: svn://10.0.0.236/trunk@84702 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
dbaron%fas.harvard.edu
2001-01-10 04:04:08 +00:00
parent 11048f6c78
commit 7deb350f0f
2 changed files with 2 additions and 28 deletions

View File

@@ -264,12 +264,6 @@ void nsHTMLTokenizer::PrependTokens(nsDeque& aDeque){
}
static nsDeque& GetTempStack() {
static nsDeque theTempStack(0);
return theTempStack;
}
/**
* This is a utilty method for ScanDocStructure, which finds a given
* tag in the stack.
@@ -333,7 +327,7 @@ nsresult nsHTMLTokenizer::ScanDocStructure(PRBool aFinalChunk) {
theRootToken=(CHTMLToken*)mTokenDeque.ObjectAt(mTokenScanPos); //init to root
nsDeque &theStack=GetTempStack();
nsDeque theStack(0);
eHTMLTags theRootTag=eHTMLTag_unknown;
CHTMLToken *theToken=theRootToken; //init to root
PRInt32 theStackDepth=0;
@@ -417,7 +411,6 @@ nsresult nsHTMLTokenizer::ScanDocStructure(PRBool aFinalChunk) {
theToken=(CHTMLToken*)mTokenDeque.ObjectAt(++mTokenScanPos);
}
theStack.Empty();
return result;
}
@@ -637,12 +630,6 @@ nsresult nsHTMLTokenizer::ConsumeScriptContent(nsScanner& aScanner,CToken*& aTok
return result;
}
nsString& GetScratchString(void) {
static nsString gScratchString;
gScratchString.Truncate(0);
return gScratchString;
}
/**
*
* @update gess12/28/98