Removed last instance of using Strcmp to check for a set/get

method. Replaced with check for flag.
This commit is contained in:
Richard Beare 2018-09-10 21:57:19 +10:00
commit 504ef74948

View file

@ -1886,11 +1886,7 @@ int R::functionWrapper(Node *n) {
/* Add the name of this member to a list for this class_name.
We will dump all these at the end. */
int nlen = Len(iname);
char *ptr = Char(iname);
bool isSet(0);
if (nlen > 4) isSet = Strcmp(NewString(&ptr[nlen-4]), "_set") == 0;
bool isSet(GetFlag(n, "memberset"));
String *tmp = NewString("");
Printf(tmp, "%s_%s", class_name, isSet ? "set" : "get");