View source code
Display the source code in dmd/expression.d from which this page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page. Requires a signed-in GitHub account. This works well for small changes. If you'd like to make larger changes you may want to consider using local clone.

Class dmd.expression.CommaExp

class CommaExp
  : BinExp ;


allowCommaExp boolTemporary variable to enable / disable deprecation of comma expression depending on the context. Since most constructor calls are rewritting, the only place where false will be passed will be from the parser.
isGenerated const(bool)This is needed because AssignExp rewrites CommaExp, hence it needs to trigger the deprecation.


allow If the argument is a CommaExp, set a flag to prevent deprecation messages
accept Visits this AST node using the given visitor.
addDtorHook Destructors are attached to VarDeclarations. Hence, if expression returns a temp that needs a destructor, make sure and create a VarDeclaration for that temp.
addressOf Take address of expression.
checkNogc Calling function f. Check the @nogc-ness, i.e. if we're in a @nogc function we can only call other @nogc functions. Returns true if error occurs.
checkPostblit Check that the postblit is callable if t is an array of structs. Returns true if error happens.
checkPurity Calling function f. Check the purity, i.e. if we're in a pure function we can only call other pure functions. Returns true if error occurs.
checkPurity Accessing variable v. Check for purity and safety violations. Returns true if error occurs.
checkReadModifyWrite Check whether the expression allows RMW operations, error with rmw operator diagnostic if not. ex is the RHS expression, or NULL if ++/-- is used (for diagnostics) Returns true if error occurs.
checkSafety Calling function f. Check the safety, i.e. if we're in a @safe function we can only call @safe or @trusted functions. Returns true if error occurs.
checkType Check that the expression has a valid type. If not, generates an error "... has no type".
checkValue Check that the expression has a valid value. If not, generates an error "... has no value".
combine Combine e1 and e2 by CommaExp if both are not NULL.
copy Does *not* do a deep copy.
deinitialize Deinitializes the global state of the compiler.
deref If this is a reference, dereference it.
extractLast If 'e' is a tree of commas, returns the rightmost expression by stripping off it from the tree. The remained part of the tree is returned via e0. Otherwise 'e' is directly returned and e0 is set to NULL.
factory Create instance of class specified by the fully qualified name classname. The class must either have no constructors or have a default constructor.
incompatibleTypes The types for a binary expression are incompatible. Print error message.
isBool Does this expression statically evaluate to a boolean 'result' (true or false)?
isLvalue Return !=0 if expression is an lvalue.
opCmp Compare with another Object obj.
opEquals Test whether this is equal to o. The default implementation only compares by identity (using the is operator). Generally, overrides for opEquals should attempt to compare objects by their contents.
resolveLoc Resolve _FILE__, _LINE__, _MODULE__, _FUNCTION__, _PRETTY_FUNCTION__, _FILE_FULL_PATH__ to loc.
setNoderefOperands Mark the operands as will never be dereferenced, which is useful info for @safe checks. Do before semantic() on operands rewrites them.
toBoolean If expression can be tested for true or false, returns the modified expression. Otherwise returns ErrorExp.
toHash Compute hash function for Object.
toLvalue Give error if we're not an lvalue. If we can, convert expression to be an lvalue.
toString Convert Object to a human readable string.


Walter Bright


Boost License 1.0