1] As of now, the this pointer is treated as an accessor (e.g., return this->dm; in C++) and a modifier (e.g., this["index"] = value; for indexers in C#) as few examples. However, more consideration of its usage is needed. For example, returning a pointer alone (e.g., return this;) is ignored for stereotypes such as get, property, and predicate. Direct modification (e.g., this = value;) is also not considered. More analysis on the usage of this is needed.
2] For the literal free function stereotype, we currently only stereotype a free function as a literal only if it does not use any parameters. However, we probably also need to consider the usage of globals and/or static variables. That is, a literal should not use parameters, globals, and/or statics.
1] As of now, the
thispointer is treated as an accessor (e.g.,return this->dm;in C++) and a modifier (e.g.,this["index"] = value;for indexers in C#) as few examples. However, more consideration of its usage is needed. For example, returning a pointer alone (e.g.,return this;) is ignored for stereotypes such asget, property, and predicate. Direct modification (e.g.,this = value;) is also not considered. More analysis on the usage ofthisis needed.2] For the
literalfree function stereotype, we currently only stereotype a free function as aliteralonly if it does not use any parameters. However, we probably also need to consider the usage of globals and/or static variables. That is, aliteralshould not use parameters, globals, and/or statics.