Skip to content

Commit

Permalink
Write markers into resolution stream.
Browse files Browse the repository at this point in the history
Change-Id: I84092ac81b67637d2975ae331034207027740191
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/175960
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
  • Loading branch information
scheglov authored and commit-bot@chromium.org committed Dec 14, 2020
1 parent 34939ac commit 05cce14
Show file tree
Hide file tree
Showing 6 changed files with 1,048 additions and 52 deletions.
8 changes: 6 additions & 2 deletions pkg/analyzer/lib/src/dart/analysis/driver.dart
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ import 'package:analyzer/src/summary/api_signature.dart';
import 'package:analyzer/src/summary/format.dart';
import 'package:analyzer/src/summary/idl.dart';
import 'package:analyzer/src/summary/package_bundle_reader.dart';
import 'package:analyzer/src/summary2/ast_binary_flags.dart';
import 'package:meta/meta.dart';

/// TODO(scheglov) We could use generalized Function in
Expand Down Expand Up @@ -85,7 +86,7 @@ typedef WorkToWaitAfterComputingResult = Future<void> Function(String path);
/// TODO(scheglov) Clean up the list of implicitly analyzed files.
class AnalysisDriver implements AnalysisDriverGeneric {
/// The version of data format, should be incremented on every format change.
static const int DATA_VERSION = 117;
static const int DATA_VERSION = 118;

/// The length of the list returned by [_computeDeclaredVariablesSignature].
static const int _declaredVariablesSignatureLength = 4;
Expand Down Expand Up @@ -147,7 +148,7 @@ class AnalysisDriver implements AnalysisDriverGeneric {
_declaredVariablesSignatureLength);

/// The salt to mix into all hashes used as keys for linked data.
final Uint32List _saltForResolution = Uint32List(2 +
final Uint32List _saltForResolution = Uint32List(3 +
AnalysisOptionsImpl.signatureLength +
_declaredVariablesSignatureLength);

Expand Down Expand Up @@ -1596,6 +1597,9 @@ class AnalysisDriver implements AnalysisDriverGeneric {
_saltForResolution[index] = enableIndex ? 1 : 0;
index++;

_saltForResolution[index] = enableDebugResolutionMarkers ? 1 : 0;
index++;

_saltForResolution.setAll(index, _analysisOptions.signature);
index += AnalysisOptionsImpl.signatureLength;

Expand Down
Loading

0 comments on commit 05cce14

Please sign in to comment.