File tree Expand file tree Collapse file tree 2 files changed +7
-19
lines changed
test/API/lang/swift/other_arch_dylib Expand file tree Collapse file tree 2 files changed +7
-19
lines changed Original file line number Diff line number Diff line change @@ -2929,7 +2929,9 @@ std::optional<SwiftScratchContextReader> Target::GetSwiftScratchContext(
2929
2929
}
2930
2930
2931
2931
// Opt into the per-module scratch context if we find incompatible triples.
2932
- if (!m_use_scratch_typesystem_per_module) {
2932
+ if (!m_use_scratch_typesystem_per_module &&
2933
+ !ModuleList::GetGlobalModuleListProperties ()
2934
+ .GetUseSwiftPreciseCompilerInvocation ()) {
2933
2935
TargetSP target_sp = exe_scope.CalculateTarget ();
2934
2936
if (lldb_module) {
2935
2937
auto module_arch = lldb_module->GetArchitecture ();
Original file line number Diff line number Diff line change @@ -33,21 +33,7 @@ def test(self):
33
33
self .expect ("expression 1" , substrs = ['1' ])
34
34
35
35
# Check the types log.
36
- import re
37
- import io
38
- types_logfile = io .open (types_log , "r" , encoding = 'utf-8' )
39
- re0 = re .compile (r'SwiftASTContextForExpressions::LogConfiguration().*arm64-apple-macosx' )
40
- re1 = re .compile (r'Enabling per-module Swift scratch context' )
41
- re2 = re .compile (r'wiftASTContextForExpressions..OtherArch..::LogConfiguration().*arm64e-apple-macosx' )
42
- found = 0
43
- for line in types_logfile :
44
- if self .TraceOn ():
45
- print (line [:- 1 ])
46
- if found == 0 and re0 .search (line ):
47
- found = 1
48
- elif found == 1 and re1 .search (line ):
49
- found = 2
50
- elif found == 2 and re2 .search (line ):
51
- found = 3
52
- break
53
- self .assertEquals (found , 3 )
36
+ self .filecheck ('platform shell cat "%s"' % types_log , __file__ )
37
+ # CHECK: SwiftASTContextForExpressions::LogConfiguration() arm64-apple-macosx
38
+ # CHECK: Enabling per-module Swift scratch context
39
+ # CHECK: {{SwiftASTContextForExpressions..OtherArch..}}::LogConfiguration() arm64e-apple-macosx
You can’t perform that action at this time.
0 commit comments