@@ -398,35 +398,35 @@ pub struct CReaderCacheKey {
398
398
// check whether the type has various kinds of types in it without
399
399
// recursing over the type itself.
400
400
bitflags ! {
401
- flags TypeFlags : u32 {
402
- const HAS_PARAMS = 1 << 0 ,
403
- const HAS_SELF = 1 << 1 ,
404
- const HAS_TY_INFER = 1 << 2 ,
405
- const HAS_RE_INFER = 1 << 3 ,
406
- const HAS_RE_SKOL = 1 << 4 ,
407
- const HAS_RE_EARLY_BOUND = 1 << 5 ,
408
- const HAS_FREE_REGIONS = 1 << 6 ,
409
- const HAS_TY_ERR = 1 << 7 ,
410
- const HAS_PROJECTION = 1 << 8 ,
401
+ pub struct TypeFlags : u32 {
402
+ const HAS_PARAMS = 1 << 0 ;
403
+ const HAS_SELF = 1 << 1 ;
404
+ const HAS_TY_INFER = 1 << 2 ;
405
+ const HAS_RE_INFER = 1 << 3 ;
406
+ const HAS_RE_SKOL = 1 << 4 ;
407
+ const HAS_RE_EARLY_BOUND = 1 << 5 ;
408
+ const HAS_FREE_REGIONS = 1 << 6 ;
409
+ const HAS_TY_ERR = 1 << 7 ;
410
+ const HAS_PROJECTION = 1 << 8 ;
411
411
412
412
// FIXME: Rename this to the actual property since it's used for generators too
413
- const HAS_TY_CLOSURE = 1 << 9 ,
413
+ const HAS_TY_CLOSURE = 1 << 9 ;
414
414
415
415
// true if there are "names" of types and regions and so forth
416
416
// that are local to a particular fn
417
- const HAS_LOCAL_NAMES = 1 << 10 ,
417
+ const HAS_LOCAL_NAMES = 1 << 10 ;
418
418
419
419
// Present if the type belongs in a local type context.
420
420
// Only set for TyInfer other than Fresh.
421
- const KEEP_IN_LOCAL_TCX = 1 << 11 ,
421
+ const KEEP_IN_LOCAL_TCX = 1 << 11 ;
422
422
423
423
// Is there a projection that does not involve a bound region?
424
424
// Currently we can't normalize projections w/ bound regions.
425
- const HAS_NORMALIZABLE_PROJECTION = 1 << 12 ,
425
+ const HAS_NORMALIZABLE_PROJECTION = 1 << 12 ;
426
426
427
427
const NEEDS_SUBST = TypeFlags :: HAS_PARAMS . bits |
428
428
TypeFlags :: HAS_SELF . bits |
429
- TypeFlags :: HAS_RE_EARLY_BOUND . bits,
429
+ TypeFlags :: HAS_RE_EARLY_BOUND . bits;
430
430
431
431
// Flags representing the nominal content of a type,
432
432
// computed by FlagsComputation. If you add a new nominal
@@ -442,7 +442,7 @@ bitflags! {
442
442
TypeFlags :: HAS_PROJECTION . bits |
443
443
TypeFlags :: HAS_TY_CLOSURE . bits |
444
444
TypeFlags :: HAS_LOCAL_NAMES . bits |
445
- TypeFlags :: KEEP_IN_LOCAL_TCX . bits,
445
+ TypeFlags :: KEEP_IN_LOCAL_TCX . bits;
446
446
}
447
447
}
448
448
@@ -1258,13 +1258,13 @@ pub struct Destructor {
1258
1258
}
1259
1259
1260
1260
bitflags ! {
1261
- flags AdtFlags : u32 {
1262
- const NO_ADT_FLAGS = 0 ,
1263
- const IS_ENUM = 1 << 0 ,
1264
- const IS_PHANTOM_DATA = 1 << 1 ,
1265
- const IS_FUNDAMENTAL = 1 << 2 ,
1266
- const IS_UNION = 1 << 3 ,
1267
- const IS_BOX = 1 << 4 ,
1261
+ pub struct AdtFlags : u32 {
1262
+ const NO_ADT_FLAGS = 0 ;
1263
+ const IS_ENUM = 1 << 0 ;
1264
+ const IS_PHANTOM_DATA = 1 << 1 ;
1265
+ const IS_FUNDAMENTAL = 1 << 2 ;
1266
+ const IS_UNION = 1 << 3 ;
1267
+ const IS_BOX = 1 << 4 ;
1268
1268
}
1269
1269
}
1270
1270
@@ -1357,18 +1357,18 @@ pub enum AdtKind { Struct, Union, Enum }
1357
1357
1358
1358
bitflags ! {
1359
1359
#[ derive( RustcEncodable , RustcDecodable , Default ) ]
1360
- flags ReprFlags : u8 {
1361
- const IS_C = 1 << 0 ,
1362
- const IS_PACKED = 1 << 1 ,
1363
- const IS_SIMD = 1 << 2 ,
1360
+ pub struct ReprFlags : u8 {
1361
+ const IS_C = 1 << 0 ;
1362
+ const IS_PACKED = 1 << 1 ;
1363
+ const IS_SIMD = 1 << 2 ;
1364
1364
// Internal only for now. If true, don't reorder fields.
1365
- const IS_LINEAR = 1 << 3 ,
1365
+ const IS_LINEAR = 1 << 3 ;
1366
1366
1367
1367
// Any of these flags being set prevent field reordering optimisation.
1368
1368
const IS_UNOPTIMISABLE = ReprFlags :: IS_C . bits |
1369
1369
ReprFlags :: IS_PACKED . bits |
1370
1370
ReprFlags :: IS_SIMD . bits |
1371
- ReprFlags :: IS_LINEAR . bits,
1371
+ ReprFlags :: IS_LINEAR . bits;
1372
1372
}
1373
1373
}
1374
1374
0 commit comments