Helper functions.

This commit is contained in:
chriseth
2017-07-11 11:24:41 +02:00
parent 6fa5d47f8f
commit 01a1296e90
4 changed files with 40 additions and 0 deletions
+4
View File
@@ -650,6 +650,10 @@ public:
bool isLocalVariable() const { return !!dynamic_cast<CallableDeclaration const*>(scope()); }
/// @returns true if this variable is a parameter or return parameter of a function.
bool isCallableParameter() const;
/// @returns true if this variable is a return parameter of a function.
bool isReturnParameter() const;
/// @returns true if this variable is a local variable or return parameter.
bool isLocalOrReturn() const;
/// @returns true if this variable is a parameter (not return parameter) of an external function.
bool isExternalCallableParameter() const;
/// @returns true if the type of the variable does not need to be specified, i.e. it is declared