@@ -147,13 +147,6 @@ enum ActionKind {
147147
148148// / The kind of a file that we've been handed as an input.
149149class InputKind {
150- private:
151- Language Lang;
152- unsigned Fmt : 3 ;
153- unsigned Preprocessed : 1 ;
154- unsigned HeaderUnit : 3 ;
155- unsigned IsHeader : 1 ;
156-
157150public:
158151 // / The input file format.
159152 enum Format {
@@ -172,6 +165,18 @@ class InputKind {
172165 HeaderUnit_Abs
173166 };
174167
168+ private:
169+ Language Lang;
170+ LLVM_PREFERRED_TYPE (Format)
171+ unsigned Fmt : 3 ;
172+ LLVM_PREFERRED_TYPE (bool )
173+ unsigned Preprocessed : 1 ;
174+ LLVM_PREFERRED_TYPE (HeaderUnitKind)
175+ unsigned HeaderUnit : 3 ;
176+ LLVM_PREFERRED_TYPE (bool )
177+ unsigned IsHeader : 1 ;
178+
179+ public:
175180 constexpr InputKind (Language L = Language::Unknown, Format F = Source,
176181 bool PP = false , HeaderUnitKind HU = HeaderUnit_None,
177182 bool HD = false )
@@ -266,88 +271,116 @@ class FrontendInputFile {
266271class FrontendOptions {
267272public:
268273 // / Disable memory freeing on exit.
274+ LLVM_PREFERRED_TYPE (bool )
269275 unsigned DisableFree : 1 ;
270276
271277 // / When generating PCH files, instruct the AST writer to create relocatable
272278 // / PCH files.
279+ LLVM_PREFERRED_TYPE (bool )
273280 unsigned RelocatablePCH : 1 ;
274281
275282 // / Show the -help text.
283+ LLVM_PREFERRED_TYPE (bool )
276284 unsigned ShowHelp : 1 ;
277285
278286 // / Show frontend performance metrics and statistics.
287+ LLVM_PREFERRED_TYPE (bool )
279288 unsigned ShowStats : 1 ;
280289
290+ LLVM_PREFERRED_TYPE (bool )
281291 unsigned AppendStats : 1 ;
282292
283293 // / print the supported cpus for the current target
294+ LLVM_PREFERRED_TYPE (bool )
284295 unsigned PrintSupportedCPUs : 1 ;
285296
286297 // / Print the supported extensions for the current target.
298+ LLVM_PREFERRED_TYPE (bool )
287299 unsigned PrintSupportedExtensions : 1 ;
288300
289301 // / Show the -version text.
302+ LLVM_PREFERRED_TYPE (bool )
290303 unsigned ShowVersion : 1 ;
291304
292305 // / Apply fixes even if there are unfixable errors.
306+ LLVM_PREFERRED_TYPE (bool )
293307 unsigned FixWhatYouCan : 1 ;
294308
295309 // / Apply fixes only for warnings.
310+ LLVM_PREFERRED_TYPE (bool )
296311 unsigned FixOnlyWarnings : 1 ;
297312
298313 // / Apply fixes and recompile.
314+ LLVM_PREFERRED_TYPE (bool )
299315 unsigned FixAndRecompile : 1 ;
300316
301317 // / Apply fixes to temporary files.
318+ LLVM_PREFERRED_TYPE (bool )
302319 unsigned FixToTemporaries : 1 ;
303320
304321 // / Emit ARC errors even if the migrator can fix them.
322+ LLVM_PREFERRED_TYPE (bool )
305323 unsigned ARCMTMigrateEmitARCErrors : 1 ;
306324
307325 // / Skip over function bodies to speed up parsing in cases you do not need
308326 // / them (e.g. with code completion).
327+ LLVM_PREFERRED_TYPE (bool )
309328 unsigned SkipFunctionBodies : 1 ;
310329
311330 // / Whether we can use the global module index if available.
331+ LLVM_PREFERRED_TYPE (bool )
312332 unsigned UseGlobalModuleIndex : 1 ;
313333
314334 // / Whether we can generate the global module index if needed.
335+ LLVM_PREFERRED_TYPE (bool )
315336 unsigned GenerateGlobalModuleIndex : 1 ;
316337
317338 // / Whether we include declaration dumps in AST dumps.
339+ LLVM_PREFERRED_TYPE (bool )
318340 unsigned ASTDumpDecls : 1 ;
319341
320342 // / Whether we deserialize all decls when forming AST dumps.
343+ LLVM_PREFERRED_TYPE (bool )
321344 unsigned ASTDumpAll : 1 ;
322345
323346 // / Whether we include lookup table dumps in AST dumps.
347+ LLVM_PREFERRED_TYPE (bool )
324348 unsigned ASTDumpLookups : 1 ;
325349
326350 // / Whether we include declaration type dumps in AST dumps.
351+ LLVM_PREFERRED_TYPE (bool )
327352 unsigned ASTDumpDeclTypes : 1 ;
328353
329354 // / Whether we are performing an implicit module build.
355+ LLVM_PREFERRED_TYPE (bool )
330356 unsigned BuildingImplicitModule : 1 ;
331357
332358 // / Whether to use a filesystem lock when building implicit modules.
359+ LLVM_PREFERRED_TYPE (bool )
333360 unsigned BuildingImplicitModuleUsesLock : 1 ;
334361
335362 // / Whether we should embed all used files into the PCM file.
363+ LLVM_PREFERRED_TYPE (bool )
336364 unsigned ModulesEmbedAllFiles : 1 ;
337365
338366 // / Whether timestamps should be written to the produced PCH file.
367+ LLVM_PREFERRED_TYPE (bool )
339368 unsigned IncludeTimestamps : 1 ;
340369
341370 // / Should a temporary file be used during compilation.
371+ LLVM_PREFERRED_TYPE (bool )
342372 unsigned UseTemporary : 1 ;
343373
344374 // / When using -emit-module, treat the modulemap as a system module.
375+ LLVM_PREFERRED_TYPE (bool )
345376 unsigned IsSystemModule : 1 ;
346377
347378 // / Output (and read) PCM files regardless of compiler errors.
379+ LLVM_PREFERRED_TYPE (bool )
348380 unsigned AllowPCMWithCompilerErrors : 1 ;
349381
350382 // / Whether to share the FileManager when building modules.
383+ LLVM_PREFERRED_TYPE (bool )
351384 unsigned ModulesShareFileManager : 1 ;
352385
353386 CodeCompleteOptions CodeCompleteOpts;
0 commit comments