ALAppExtensions icon indicating copy to clipboard operation
ALAppExtensions copied to clipboard

[Bug] codeunit 413 AnalysisViewEntryToGLEntries - Param must be temporary

Open Daniamstutz opened this issue 4 years ago • 1 comments

As the name of the second variable implies, it must be temporary.

At the moment it is not temporary: procedure GetGLEntries(var AnalysisViewEntry: Record "Analysis View Entry"; var TempGLEntry: Record "G/L Entry")

It must be: procedure GetGLEntries(var AnalysisViewEntry: Record "Analysis View Entry"; var TempGLEntry: Record "G/L Entry" temporary)

Daniamstutz avatar Apr 20 '22 12:04 Daniamstutz

When passing by var the temporary property in the signature of procedure doesn't really make a difference, so this will work as expected either way as long as the record you pass into the procedure is temporary. I agree that generally it would be cleaner to have this tagged as temp, but since it's a global procedure, changing its signature for no good reason isn't preferable.

Stepanenko-Vadim avatar Apr 27 '22 05:04 Stepanenko-Vadim