Пример #1
0
        private void BindFunctionHeader <T>(T parent, FunctionHeaderNode header, string stateName)
            where T : SyntaxNode, IStatementBlock
        {
            _scriptType.TryGetFunction(stateName, header.Identifier.Text, out var type);
            header.CompilerType = type;

            if (type != null)
            {
                parent.CompilerScope = type.FunctionScope;

                header.Flags |= type.bGlobal ? LanguageFlags.Global : LanguageFlags.None;
                header.Flags |= type.bNative ? LanguageFlags.Native : LanguageFlags.None;

#if FALLOUT4
                header.Flags |= type.bBetaOnly ? LanguageFlags.BetaOnly : LanguageFlags.None;
                header.Flags |= type.bDebugOnly ? LanguageFlags.DebugOnly : LanguageFlags.None;
#endif
            }
        }
Пример #2
0
 public virtual T VisitFunctionHeader(FunctionHeaderNode node, T1 t1)
 {
     return(VisitDefault(node, t1));
 }