| 1929 | |
| 1930 | |
| 1931 | static void globalstat (LexState *ls) { |
| 1932 | /* globalstat -> (GLOBAL) attrib '*' |
| 1933 | globalstat -> (GLOBAL) attrib NAME attrib {',' NAME attrib} */ |
| 1934 | FuncState *fs = ls->fs; |
| 1935 | /* get prefixed attribute (if any); default is regular global variable */ |
| 1936 | lu_byte defkind = getglobalattribute(ls, GDKREG); |
| 1937 | if (!testnext(ls, '*')) |
| 1938 | globalnames(ls, defkind); |
| 1939 | else { |
| 1940 | /* use NULL as name to represent '*' entries */ |
| 1941 | new_varkind(ls, NULL, defkind); |
| 1942 | fs->nactvar++; /* activate declaration */ |
| 1943 | } |
| 1944 | } |
| 1945 | |
| 1946 | |
| 1947 | static void globalfunc (LexState *ls, int line) { |
no test coverage detected