AttributeViolation

Stores a reason why a function failed to infer a function attribute like @safe or pure

Has two modes: - a regular safety error, stored in (fmtStr, arg0, arg1) - a call to a function without the attribute, which is a special case, because in that case, that function might recursively also have a AttributeViolation. This way, in case of a big call stack, the error can go down all the way to the root cause. The FunctionDeclaration is then stored in arg0 and fmtStr must be null.

Members

Variables

arg0
RootObject arg0;
arg1
RootObject arg1;
arg2
RootObject arg2;

Arguments for up to two %s format specifiers in format string

fmtStr
const(char)* fmtStr;

printf-style format string

loc
Loc loc;

location of error

Meta