Feature #8514

RETNIL() macro

Added by alef about 7 years ago. Updated almost 7 years ago.

Status:Closed Start date:01/25/2010
Priority:Normal Due date:
Assignee:killswitch % Done:


Target version:v0.3.1
Component: Affected Version:
Close Reason:


A function could set a var to nil and use it as return, like source:/addons/common/fnc_defaultParam.sqf.
The macro
1 #define RETNIL(x) call{if(isNil{x})then{nil}else{x}}
could be used here and there to avoid errors dereferencing undefined vars.

Change the name if don't like it.


Updated by killswitch about 7 years ago

  • Status changed from New to Resolved
  • Assignee set to killswitch
  • Target version set to v0.3.x
  • % Done changed from 0 to 100

Updated by Sickboy about 7 years ago

  • Status changed from Resolved to Closed

Updated by Sickboy almost 7 years ago

  • Target version changed from v0.3.x to v0.3.1

Also available in: Atom PDF