@@ -34,49 +34,6 @@ SILValue SILGenFunction::emitSelfDecl(VarDecl *selfDecl) {
34
34
return selfValue;
35
35
}
36
36
37
- namespace {
38
-
39
- // / Cleanup that writes back to an inout argument on function exit.
40
- class CleanupWriteBackToInOut : public Cleanup {
41
- VarDecl *var;
42
- SILValue inoutAddr;
43
-
44
- public:
45
- CleanupWriteBackToInOut (VarDecl *var, SILValue inoutAddr)
46
- : var(var), inoutAddr(inoutAddr) {}
47
-
48
- void emit (SILGenFunction &SGF, CleanupLocation l,
49
- ForUnwind_t forUnwind) override {
50
- // Assign from the local variable to the inout address with an
51
- // 'autogenerated' copyaddr.
52
- l.markAutoGenerated ();
53
- SGF.B .createCopyAddr (l, SGF.VarLocs [var].value , inoutAddr,
54
- IsNotTake, IsNotInitialization);
55
- }
56
- };
57
- } // end anonymous namespace
58
-
59
-
60
- namespace {
61
- class StrongReleaseCleanup : public Cleanup {
62
- SILValue box;
63
- public:
64
- StrongReleaseCleanup (SILValue box) : box(box) {}
65
- void emit (SILGenFunction &SGF, CleanupLocation l,
66
- ForUnwind_t forUnwind) override {
67
- SGF.B .emitDestroyValueOperation (l, box);
68
- }
69
-
70
- void dump (SILGenFunction &) const override {
71
- #ifndef NDEBUG
72
- llvm::errs () << " DeallocateValueBuffer\n "
73
- << " State: " << getState () << " box: " << box << " \n " ;
74
- #endif
75
- }
76
- };
77
- } // end anonymous namespace
78
-
79
-
80
37
namespace {
81
38
class EmitBBArguments : public CanTypeVisitor <EmitBBArguments,
82
39
/* RetTy*/ ManagedValue>
0 commit comments