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

Unified Diff: third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp

Issue 2386893002: Reformat comments in core/html/parser (Closed)
Patch Set: self review Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
diff --git a/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp b/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
index 2e87c96e343520b7caf7c04ea9b4e0dc2821b744..f64163e8f4c38dd11617c737df8f084b6713a17f 100644
--- a/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
+++ b/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
@@ -208,14 +208,16 @@ void HTMLScriptRunner::executePendingScriptAndDispatchEvent(
ScriptSourceCode sourceCode = pendingScript->getSource(
documentURLForScriptExecution(m_document), errorOccurred);
- // Stop watching loads before executeScript to prevent recursion if the script reloads itself.
+ // Stop watching loads before executeScript to prevent recursion if the script
+ // reloads itself.
pendingScript->stopWatchingForLoad();
if (!isExecutingScript()) {
Microtask::performCheckpoint(V8PerIsolateData::mainThreadIsolate());
if (pendingScriptType == ScriptStreamer::ParsingBlocking) {
m_hasScriptsWaitingForResources = !m_document->isScriptExecutionReady();
- // The parser cannot be unblocked as a microtask requested another resource
+ // The parser cannot be unblocked as a microtask requested another
+ // resource
if (m_hasScriptsWaitingForResources)
return;
}
@@ -348,14 +350,18 @@ void HTMLScriptRunner::execute(Element* scriptElement,
runScript(scriptElement, scriptStartPosition);
if (hasParserBlockingScript()) {
- if (isExecutingScript())
- return; // Unwind to the outermost HTMLScriptRunner::execute before continuing parsing.
+ if (isExecutingScript()) {
+ // Unwind to the outermost HTMLScriptRunner::execute before continuing
+ // parsing.
+ return;
+ }
traceParserBlockingScript(m_parserBlockingScript.get(),
!m_document->isScriptExecutionReady());
m_parserBlockingScript->markParserBlockingLoadStartTime();
- // If preload scanner got created, it is missing the source after the current insertion point. Append it and scan.
+ // If preload scanner got created, it is missing the source after the
+ // current insertion point. Append it and scan.
if (!hadPreloadScanner && m_host->hasPreloadScanner())
m_host->appendCurrentInputStreamToPreloadScannerAndScan();
executeParsingBlockingScripts();
@@ -420,9 +426,9 @@ void HTMLScriptRunner::requestParsingBlockingScript(Element* element) {
ASSERT(m_parserBlockingScript->resource());
- // We only care about a load callback if resource is not already
- // in the cache. Callers will attempt to run the m_parserBlockingScript
- // if possible before returning control to the parser.
+ // We only care about a load callback if resource is not already in the cache.
+ // Callers will attempt to run the m_parserBlockingScript if possible before
+ // returning control to the parser.
if (!m_parserBlockingScript->isReady()) {
if (m_document->frame()) {
ScriptState* scriptState = ScriptState::forMainWorld(m_document->frame());

Powered by Google App Engine
This is Rietveld 408576698