// Map the decl to the existing index.
if (Index) {
GlobalIndices[VD] = *Index;
- return {};
+ return std::nullopt;
}
return Index;
GlobalIndices[VD] = *Idx;
return Idx;
}
- return {};
+ return std::nullopt;
}
std::optional<unsigned> Program::getOrCreateDummy(const ParmVarDecl *PD) {
DummyParams[PD] = *Idx;
return Idx;
}
- return {};
+ return std::nullopt;
}
std::optional<unsigned> Program::createGlobal(const ValueDecl *VD,
GlobalIndices[P] = *Idx;
return *Idx;
}
- return {};
+ return std::nullopt;
}
std::optional<unsigned> Program::createGlobal(const Expr *E) {
IsTemporary);
}
if (!Desc)
- return {};
+ return std::nullopt;
// Allocate a block for storage.
unsigned I = Globals.size();