Beispiel #1
0
 public sunFunctionSymbol(string name, sunParameterInfo parameters, sunNode body)
     : base(name, parameters)
 {
     if (body == null)
     {
         throw new ArgumentNullException("body");
     }
     mBody = body;
 }
Beispiel #2
0
        public static sunSymbolModifiers GetModifiers(sunNode modifierlist)
        {
            if (modifierlist == null)
            {
                return(sunSymbolModifiers.None);
            }
            var modifiers = sunSymbolModifiers.None;

            if (modifierlist.Any(i => i is sunConstModifier))
            {
                modifiers |= sunSymbolModifiers.Constant;
            }
            if (modifierlist.Any(i => i is sunLocalModifier))
            {
                modifiers |= sunSymbolModifiers.Local;
            }
            return(modifiers);
        }