diff --git a/fontes/interpretador/interpretador.ts b/fontes/interpretador/interpretador.ts index f0d220a8..6fd54123 100644 --- a/fontes/interpretador/interpretador.ts +++ b/fontes/interpretador/interpretador.ts @@ -907,9 +907,10 @@ export class Interpretador implements InterpretadorInterface { executar(declaracao: any, mostrarResultado: boolean = false): void { const resultado = declaracao.aceitar(this); if (mostrarResultado) { - const formatoTexto = this.paraTexto(resultado); - this.resultadoInterpretador.push(formatoTexto) - this.funcaoDeRetorno(formatoTexto); + this.funcaoDeRetorno(this.paraTexto(resultado)); + } + if(resultado || typeof resultado === 'boolean'){ + this.resultadoInterpretador.push(this.paraTexto(resultado)) } }