File tree 5 files changed +21
-6
lines changed
testsuite/tests/instr-cov/main_autodump/disabled_lang
5 files changed +21
-6
lines changed Original file line number Diff line number Diff line change 22
22
covlevel = "stmt" ,
23
23
mains = ["main" ],
24
24
extra_instr_args = ["--restricted-to-languages=C" ],
25
- extra_coverage_args = ["-axcov" , "--output-dir=xcov" ],
25
+ extra_coverage_args = [
26
+ "-axcov" ,
27
+ "--output-dir=xcov" ,
28
+ "--restricted-to-languages=C" ,
29
+ ],
26
30
trace_mode = "src" ,
27
31
)
28
32
check_xcov_reports ("xcov" , {"tested.c.xcov" : {"+" : {5 }, "-" : {7 }}})
39
43
covlevel = "stmt" ,
40
44
mains = ["main" ],
41
45
extra_instr_args = ["--restricted-to-languages=Ada" ],
42
- extra_coverage_args = ["-axcov" , "--output-dir=xcov" ],
46
+ extra_coverage_args = [
47
+ "-axcov" ,
48
+ "--output-dir=xcov" ,
49
+ "--restricted-to-languages=Ada" ,
50
+ ],
43
51
trace_mode = "src" ,
44
52
)
45
53
check_xcov_reports (
Original file line number Diff line number Diff line change @@ -1586,7 +1586,8 @@ package Command_Line is
1586
1586
& " C and C++. Note that main units of other languages may still be"
1587
1587
& " instrumented to dump the coverage state to trace files." ,
1588
1588
Commands => (Cmd_Setup
1589
- | Cmd_Instrument_Project => True,
1589
+ | Cmd_Instrument_Project
1590
+ | Cmd_Coverage => True,
1590
1591
others => False),
1591
1592
Internal => False,
1592
1593
Accepts_Comma_Separator => True),
Original file line number Diff line number Diff line change @@ -366,6 +366,11 @@ package body Project is
366
366
if Unit.Warned_About_Missing_Info
367
367
or else (Currently_Accepted_Trace_Kind = Binary_Trace_File
368
368
and then Unit.Language = CPP_Language)
369
+
370
+ -- Ignore units in a language that is ignored through the
371
+ -- --restricted-to-languages switch.
372
+
373
+ or else not Src_Enabled_Languages (Unit.Language)
369
374
then
370
375
return ;
371
376
end if ;
Original file line number Diff line number Diff line change @@ -121,7 +121,8 @@ package body Setup_RTS is
121
121
-- Load the project file at Project_File using the Target/RTS/Config_File
122
122
-- parameters, then try to guess the profile of the actual runtime in
123
123
-- effect (Auto_RTS_Profile) and determine the support for libraries for
124
- -- this configuration (Lib_Support).
124
+ -- this configuration (Lib_Support). Pass Db_Dir as an additional knowledge
125
+ -- base. when creating the configuration file.
125
126
--
126
127
-- Set Actual_Target, Actual_RTS_Dir and Actual_RTS_Name to the actual
127
128
-- target/RTS names for the loaded project: they can be different from
Original file line number Diff line number Diff line change @@ -223,8 +223,8 @@ package Switches is
223
223
224
224
Src_Enabled_Languages : array (Src_Supported_Language) of Boolean :=
225
225
(others => False);
226
- -- List of languages for which source files should be instrumented.
227
- -- Initialized during command line arguments parsing.
226
+ -- List of languages for which coverage analysis is enabled. Initialized
227
+ -- during command line arguments parsing.
228
228
229
229
Builtin_Support : array (Src_Supported_Language) of Boolean :=
230
230
(others => True);
You can’t perform that action at this time.
0 commit comments