@@ -35,8 +35,8 @@ CIRGenFunction::emitAutoVarAlloca(const VarDecl &d,
35
35
getContext ().getLangOpts ().ElideConstructors && d.isNRVOVariable ();
36
36
37
37
CIRGenFunction::AutoVarEmission emission (d);
38
- emission.IsEscapingByRef = d.isEscapingByref ();
39
- if (emission.IsEscapingByRef )
38
+ emission.isEscapingByRef = d.isEscapingByref ();
39
+ if (emission.isEscapingByRef )
40
40
cgm.errorNYI (d.getSourceRange (),
41
41
" emitAutoVarDecl: decl escaping by reference" );
42
42
@@ -78,7 +78,7 @@ CIRGenFunction::emitAutoVarAlloca(const VarDecl &d,
78
78
alignment);
79
79
}
80
80
81
- emission.Addr = address;
81
+ emission.addr = address;
82
82
setAddrOfLocalVar (&d, address);
83
83
84
84
return emission;
@@ -101,13 +101,13 @@ bool CIRGenFunction::isTrivialInitializer(const Expr *init) {
101
101
102
102
void CIRGenFunction::emitAutoVarInit (
103
103
const CIRGenFunction::AutoVarEmission &emission) {
104
- assert (emission.Variable && " emission was not valid!" );
104
+ assert (emission.variable && " emission was not valid!" );
105
105
106
106
// If this was emitted as a global constant, we're done.
107
107
if (emission.wasEmittedAsGlobal ())
108
108
return ;
109
109
110
- const VarDecl &d = *emission.Variable ;
110
+ const VarDecl &d = *emission.variable ;
111
111
112
112
QualType type = d.getType ();
113
113
@@ -124,7 +124,7 @@ void CIRGenFunction::emitAutoVarInit(
124
124
return ;
125
125
}
126
126
127
- const Address addr = emission.Addr ;
127
+ const Address addr = emission.addr ;
128
128
129
129
// Check whether this is a byref variable that's potentially
130
130
// captured and moved by its own initializer. If so, we'll need to
@@ -153,7 +153,7 @@ void CIRGenFunction::emitAutoVarInit(
153
153
}
154
154
155
155
mlir::Attribute constant;
156
- if (emission.IsConstantAggregate ||
156
+ if (emission.isConstantAggregate ||
157
157
d.mightBeUsableInConstantExpressions (getContext ())) {
158
158
// FIXME: Differently from LLVM we try not to emit / lower too much
159
159
// here for CIR since we are interested in seeing the ctor in some
@@ -196,7 +196,7 @@ void CIRGenFunction::emitAutoVarInit(
196
196
// FIXME(cir): migrate most of this file to use mlir::TypedAttr directly.
197
197
auto typedConstant = mlir::dyn_cast<mlir::TypedAttr>(constant);
198
198
assert (typedConstant && " expected typed attribute" );
199
- if (!emission.IsConstantAggregate ) {
199
+ if (!emission.isConstantAggregate ) {
200
200
// For simple scalar/complex initialization, store the value directly.
201
201
LValue lv = makeAddrLValue (addr, type);
202
202
assert (init && " expected initializer" );
@@ -209,7 +209,7 @@ void CIRGenFunction::emitAutoVarInit(
209
209
210
210
void CIRGenFunction::emitAutoVarCleanups (
211
211
const CIRGenFunction::AutoVarEmission &emission) {
212
- const VarDecl &d = *emission.Variable ;
212
+ const VarDecl &d = *emission.variable ;
213
213
214
214
// Check the type for a cleanup.
215
215
if (QualType::DestructionKind dtorKind = d.needsDestruction (getContext ()))
@@ -821,7 +821,7 @@ void CIRGenFunction::emitAutoVarTypeCleanup(
821
821
// original stack object, not the possibly forwarded object.
822
822
Address addr = emission.getObjectAddress (*this );
823
823
824
- const VarDecl *var = emission.Variable ;
824
+ const VarDecl *var = emission.variable ;
825
825
QualType type = var->getType ();
826
826
827
827
CleanupKind cleanupKind = NormalAndEHCleanup;
@@ -834,7 +834,7 @@ void CIRGenFunction::emitAutoVarTypeCleanup(
834
834
case QualType::DK_cxx_destructor:
835
835
// If there's an NRVO flag on the emission, we need a different
836
836
// cleanup.
837
- if (emission.NRVOFlag ) {
837
+ if (emission.nrvoFlag ) {
838
838
cgm.errorNYI (var->getSourceRange (), " emitAutoVarTypeCleanup: NRVO" );
839
839
return ;
840
840
}
0 commit comments