diff --git a/Evil Calculator/CalculatorBody.cs b/Evil Calculator/CalculatorBody.cs index e7e0873..4f8d6b9 100644 --- a/Evil Calculator/CalculatorBody.cs +++ b/Evil Calculator/CalculatorBody.cs @@ -200,7 +200,7 @@ currentOperandTextBox.ForeColor = Color.White; CalculatorPanel.Controls.Add(currentOperandTextBox); - equationManager.AcquireOutputLabels(ref equationTextBox, ref currentOperandTextBox); + equationManager.AcquireOutputLabels(equationTextBox, currentOperandTextBox); CalculatorPanel.Show(); diff --git a/Evil Calculator/EquationManager.cs b/Evil Calculator/EquationManager.cs index 877d5a7..ed8d0ac 100644 --- a/Evil Calculator/EquationManager.cs +++ b/Evil Calculator/EquationManager.cs @@ -145,12 +145,12 @@ { if (currentOperand != "") equation.Add(new Token(Token.TokenType.Operand, currentOperand)); buttonEquals.Text = "#"; - currentOperand = reverseNotationSolver.Solve(ref equation); + currentOperand = reverseNotationSolver.Solve(equation); UpdateLabels(); } } - public void AcquireOutputLabels(ref Label equationTextBox, ref Label currentOperandTextBox) + public void AcquireOutputLabels(Label equationTextBox, Label currentOperandTextBox) { outerEquationLabel = equationTextBox; outerOperandLabel = currentOperandTextBox; diff --git a/Evil Calculator/ReverseNotattionSolver.cs b/Evil Calculator/ReverseNotattionSolver.cs index 28d16fd..f68b4a3 100644 --- a/Evil Calculator/ReverseNotattionSolver.cs +++ b/Evil Calculator/ReverseNotattionSolver.cs @@ -4,7 +4,7 @@ { List equation = new(); - public string ToReverseNotation(ref List equation) + public string ToReverseNotation(List equation) { List TEMP = new List(); Stack OPERATORS = new Stack(); @@ -47,9 +47,9 @@ } - public string Solve(ref List equation) + public string Solve(List equation) { - ToReverseNotation(ref equation); + ToReverseNotation(equation); Stack stack = new Stack(); foreach (Token token in this.equation) {