Skip to content

Commit

Permalink
🐛 Corrigindo AutoFormatação de num negativos em matrizes (fix #707)
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafaelfcosta committed Jul 4, 2019
1 parent 55a34a5 commit ac5ae58
Showing 1 changed file with 11 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -514,11 +514,18 @@ public Void visitar(NoMatriz no) throws ExcecaoVisitaASA

for (int j = 0; j < totalColunas; j++) {

String valor = linha.get(j).toString();
if (linha.get(j) instanceof NoLogico) {
valor = ((NoLogico)linha.get(j)).getValor() ? "verdadeiro" : "falso";
Object valor = linha.get(j);
if(valor instanceof NoExpressaoLiteral) {
String string = valor.toString();

if (linha.get(j) instanceof NoLogico) {
string = ((NoLogico)linha.get(j)).getValor() ? "verdadeiro" : "falso";
}

saida.append(string);
}else {
((NoExpressao) valor).aceitar(this);
}
saida.append(valor);

if (j < totalColunas - 1) {
saida.append(", ");
Expand Down

0 comments on commit ac5ae58

Please sign in to comment.