File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -313,6 +313,9 @@ class Reproducer {
313313
314314 FileSpec GetReproducerPath () const ;
315315
316+ bool IsCapturing () { return static_cast <bool >(m_generator); };
317+ bool IsReplaying () { return static_cast <bool >(m_loader); };
318+
316319protected:
317320 llvm::Error SetCapture (llvm::Optional<FileSpec> root);
318321 llvm::Error SetReplay (llvm::Optional<FileSpec> root);
Original file line number Diff line number Diff line change @@ -88,7 +88,7 @@ class CommandObjectReproducerGenerate : public CommandObjectParsed {
8888 auto &r = Reproducer::Instance ();
8989 if (auto generator = r.GetGenerator ()) {
9090 generator->Keep ();
91- } else if (r.GetLoader ()) {
91+ } else if (r.IsReplaying ()) {
9292 // Make this operation a NOP in replay mode.
9393 result.SetStatus (eReturnStatusSuccessFinishNoResult);
9494 return result.Succeeded ();
@@ -132,9 +132,9 @@ class CommandObjectReproducerStatus : public CommandObjectParsed {
132132 }
133133
134134 auto &r = Reproducer::Instance ();
135- if (r.GetGenerator ()) {
135+ if (r.IsCapturing ()) {
136136 result.GetOutputStream () << " Reproducer is in capture mode.\n " ;
137- } else if (r.GetLoader ()) {
137+ } else if (r.IsReplaying ()) {
138138 result.GetOutputStream () << " Reproducer is in replay mode.\n " ;
139139 } else {
140140 result.GetOutputStream () << " Reproducer is off.\n " ;
You can’t perform that action at this time.
0 commit comments