Macros for SAS Application Developers
https://github.com/sasjs/core
Loading...
Searching...
No Matches
mcf_init.sas
Go to the documentation of this file.
1
/**
2
@file
3
@brief Sets up the mcf_xx functions
4
@details
5
There is no (efficient) way to determine if an mcf_xx macro has already been
6
invoked. So, we make use of a global macro variable list to keep track.
7
8
Usage:
9
10
%mcf_init(MCF_LENGTH)
11
12
Returns:
13
14
> 1 (if already initialised) else 0
15
16
@param [in] func The function to be initialised
17
18
<h4> Related Macros </h4>
19
@li mcf_init.test.sas
20
21
**/
22
23
%macro mcf_init(func
24
)
/*/STORE SOURCE*/
;
25
26
%let func=%upcase(&func);
27
28
/* the / character is just a seperator */
29
%global _SASJS_FUNCTIONS;
30
%
if
%index(&_SASJS_FUNCTIONS,&func/)>0 %then %
do
;
31
1
32
%
return
;
33
%end;
34
%
else
%
do
;
35
%let _SASJS_FUNCTIONS=&_SASJS_FUNCTIONS &func/;
36
0
37
%end;
38
39
%mend mcf_init;
fcmp
mcf_init.sas
Generated by
1.9.8
For more information visit the
Macro Core library
.