cast postfix in nested statement

Issue #2421 resolved
Adam Stepanek created an issue

Hi Scott,

when I have following statement

return (String) record.get(folder.get(field));

and want to use cast postfix on the folder.get(field) like folder.get(field).cast IDE erases the beginning part and converts the statement to this

return ((SObjectField) folder.get(field));

What I would expect is this

return (String) record.get((SObjectField) folder.get(field));

Thanks for looking on thins

Comments (4)

  1. Scott Wells repo owner

    Fix committed for the next build. The postfix completion template was incorrectly configured to always replace the top-most expression.

  2. Log in to comment