示例#1
0
    public bool Compile(List <string> scope)
    {
        switch (state)
        {
        case VariableManager.StructureType.Array:
            foreach (string str in scope)
            {
                if (str == GetName() && FindByText(GetName()) != -1)
                {
                    return(vet.Compile(scope));
                }
            }
            break;

        case VariableManager.StructureType.Matriz:
            foreach (string str in scope)
            {
                if (str == GetName() && FindByText(GetName()) != -1)
                {
                    return(vet.Compile(scope) && mat.Compile(scope));
                }
            }
            break;

        case VariableManager.StructureType.Variable:
            foreach (string str in scope)
            {
                if (str == GetName() && FindByText(GetName()) != -1)
                {
                    return(true);
                }
            }
            break;
        }
        return(false);
    }