def cleanup():
self.runCmd('command unalias read', check=False)
self.runCmd('command unalias rd', check=False)
+ self.runCmd('command unalias fo', check=False)
+ self.runCmd('command unalias foself', check=False)
# Execute the cleanup function during test case tear down.
self.addTearDownHook(cleanup)
self.expect('memory read -f A -c 3 `&my_ptr[0]`', substrs=['deadfeed'], matching=False)
self.expect('rd `&my_ptr[0]`', substrs=['deadfeed'], matching=False)
+
+ self.runCmd('command alias fo frame variable -O --')
+ self.runCmd('command alias foself fo self')
+
+ self.expect('help foself', substrs=['--show-all-children', '--raw-output'], matching=False)
+ self.expect('help foself', substrs=['Show frame variables.'], matching=True)
break;
}
}
+ // if this is a nested alias, it may be adding arguments on top of an already dash-dash alias
+ if ((m_is_dashdash_alias == eLazyBoolNo) && IsNestedAlias())
+ m_is_dashdash_alias = (GetUnderlyingCommand()->IsDashDashCommand() ? eLazyBoolYes : eLazyBoolNo);
}
}
return (m_is_dashdash_alias == eLazyBoolYes);
}
+bool
+CommandAlias::IsNestedAlias ()
+{
+ if (GetUnderlyingCommand())
+ return GetUnderlyingCommand()->IsAlias();
+ return false;
+}
+
std::pair<lldb::CommandObjectSP, OptionArgVectorSP>
CommandAlias::Desugar ()
{