@designliquido/delegua 0.7.6 → 0.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/package.json +78 -65
- package/fontes/avaliador-sintatico/avaliador-sintatico-base.d.ts +63 -0
- package/fontes/avaliador-sintatico/avaliador-sintatico-base.js +180 -0
- package/fontes/avaliador-sintatico/avaliador-sintatico-base.js.map +1 -0
- package/fontes/avaliador-sintatico/avaliador-sintatico.d.ts +5 -4
- package/fontes/avaliador-sintatico/avaliador-sintatico.js +189 -188
- package/fontes/avaliador-sintatico/avaliador-sintatico.js.map +1 -1
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-egua-classico.d.ts +34 -32
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-egua-classico.js +154 -148
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-egua-classico.js.map +1 -1
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-eguap.d.ts +13 -12
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-eguap.js +144 -142
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-eguap.js.map +1 -1
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-visualg.d.ts +48 -0
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-visualg.js +297 -0
- package/fontes/avaliador-sintatico/dialetos/avaliador-sintatico-visualg.js.map +1 -0
- package/fontes/avaliador-sintatico/erro-avaliador-sintatico.d.ts +1 -1
- package/fontes/avaliador-sintatico/retornos/index.d.ts +3 -0
- package/fontes/avaliador-sintatico/retornos/index.js +20 -0
- package/fontes/avaliador-sintatico/retornos/index.js.map +1 -0
- package/fontes/avaliador-sintatico/retornos/retorno-declaracao.d.ts +3 -0
- package/fontes/avaliador-sintatico/retornos/retorno-declaracao.js +3 -0
- package/fontes/avaliador-sintatico/retornos/retorno-declaracao.js.map +1 -0
- package/fontes/avaliador-sintatico/retornos/retorno-primario.d.ts +3 -0
- package/fontes/avaliador-sintatico/retornos/retorno-primario.js +3 -0
- package/fontes/avaliador-sintatico/retornos/retorno-primario.js.map +1 -0
- package/fontes/avaliador-sintatico/retornos/retorno-resolver-declaracao.d.ts +2 -0
- package/fontes/avaliador-sintatico/retornos/retorno-resolver-declaracao.js +3 -0
- package/fontes/avaliador-sintatico/retornos/retorno-resolver-declaracao.js.map +1 -0
- package/fontes/bibliotecas/biblioteca-global.d.ts +2 -2
- package/fontes/bibliotecas/biblioteca-global.js +112 -57
- package/fontes/bibliotecas/biblioteca-global.js.map +1 -1
- package/fontes/bibliotecas/importar-biblioteca.d.ts +1 -1
- package/fontes/bibliotecas/importar-biblioteca.js +13 -14
- package/fontes/bibliotecas/importar-biblioteca.js.map +1 -1
- package/fontes/bibliotecas/primitivas-texto.js +13 -7
- package/fontes/bibliotecas/primitivas-texto.js.map +1 -1
- package/fontes/bibliotecas/primitivas-vetor.js +25 -11
- package/fontes/bibliotecas/primitivas-vetor.js.map +1 -1
- package/fontes/construtos/acesso-indice-variavel.d.ts +2 -2
- package/fontes/construtos/acesso-indice-variavel.js.map +1 -1
- package/fontes/construtos/acesso-metodo.d.ts +2 -2
- package/fontes/construtos/acesso-metodo.js.map +1 -1
- package/fontes/construtos/agrupamento.d.ts +2 -2
- package/fontes/construtos/atribuicao-sobrescrita.d.ts +1 -1
- package/fontes/construtos/atribuicao-sobrescrita.js.map +1 -1
- package/fontes/construtos/atribuir.d.ts +2 -2
- package/fontes/construtos/atribuir.js.map +1 -1
- package/fontes/construtos/binario.d.ts +2 -2
- package/fontes/construtos/binario.js.map +1 -1
- package/fontes/construtos/chamada.d.ts +2 -2
- package/fontes/construtos/chamada.js.map +1 -1
- package/fontes/construtos/conjunto.d.ts +1 -1
- package/fontes/construtos/conjunto.js.map +1 -1
- package/fontes/construtos/construto.d.ts +1 -0
- package/fontes/construtos/dicionario.d.ts +1 -1
- package/fontes/construtos/dicionario.js.map +1 -1
- package/fontes/construtos/funcao.d.ts +2 -2
- package/fontes/construtos/funcao.js.map +1 -1
- package/fontes/construtos/index.d.ts +18 -18
- package/fontes/construtos/isto.d.ts +1 -1
- package/fontes/construtos/isto.js.map +1 -1
- package/fontes/construtos/literal.d.ts +5 -4
- package/fontes/construtos/literal.js.map +1 -1
- package/fontes/construtos/logico.d.ts +1 -1
- package/fontes/construtos/logico.js.map +1 -1
- package/fontes/construtos/super.d.ts +4 -4
- package/fontes/construtos/super.js.map +1 -1
- package/fontes/construtos/unario.d.ts +1 -1
- package/fontes/construtos/unario.js.map +1 -1
- package/fontes/construtos/variavel.d.ts +2 -2
- package/fontes/construtos/variavel.js.map +1 -1
- package/fontes/construtos/vetor.d.ts +3 -3
- package/fontes/construtos/vetor.js.map +1 -1
- package/fontes/declaracoes/bloco.d.ts +4 -4
- package/fontes/declaracoes/bloco.js.map +1 -1
- package/fontes/declaracoes/classe.d.ts +2 -2
- package/fontes/declaracoes/classe.js.map +1 -1
- package/fontes/declaracoes/continua.d.ts +2 -2
- package/fontes/declaracoes/continua.js.map +1 -1
- package/fontes/declaracoes/declaracao.js +2 -2
- package/fontes/declaracoes/declaracao.js.map +1 -1
- package/fontes/declaracoes/enquanto.d.ts +2 -2
- package/fontes/declaracoes/enquanto.js.map +1 -1
- package/fontes/declaracoes/escolha.d.ts +7 -4
- package/fontes/declaracoes/escolha.js +6 -3
- package/fontes/declaracoes/escolha.js.map +1 -1
- package/fontes/declaracoes/escreva.d.ts +3 -3
- package/fontes/declaracoes/escreva.js.map +1 -1
- package/fontes/declaracoes/expressao.d.ts +3 -3
- package/fontes/declaracoes/expressao.js.map +1 -1
- package/fontes/declaracoes/fazer.d.ts +1 -1
- package/fontes/declaracoes/fazer.js.map +1 -1
- package/fontes/declaracoes/funcao.d.ts +2 -2
- package/fontes/declaracoes/funcao.js.map +1 -1
- package/fontes/declaracoes/importar.d.ts +2 -2
- package/fontes/declaracoes/importar.js.map +1 -1
- package/fontes/declaracoes/index.d.ts +1 -0
- package/fontes/declaracoes/index.js +1 -0
- package/fontes/declaracoes/index.js.map +1 -1
- package/fontes/declaracoes/leia.d.ts +12 -0
- package/fontes/declaracoes/leia.js +37 -0
- package/fontes/declaracoes/leia.js.map +1 -0
- package/fontes/declaracoes/para.d.ts +1 -1
- package/fontes/declaracoes/para.js.map +1 -1
- package/fontes/declaracoes/retorna.d.ts +2 -2
- package/fontes/declaracoes/retorna.js.map +1 -1
- package/fontes/declaracoes/se.d.ts +2 -2
- package/fontes/declaracoes/se.js.map +1 -1
- package/fontes/declaracoes/sustar.d.ts +2 -2
- package/fontes/declaracoes/sustar.js.map +1 -1
- package/fontes/declaracoes/tente.d.ts +2 -2
- package/fontes/declaracoes/tente.js.map +1 -1
- package/fontes/declaracoes/var.d.ts +5 -4
- package/fontes/declaracoes/var.js.map +1 -1
- package/fontes/delegua.d.ts +3 -3
- package/fontes/delegua.js +38 -22
- package/fontes/delegua.js.map +1 -1
- package/fontes/depuracao/cyrb53.js +6 -3
- package/fontes/depuracao/cyrb53.js.map +1 -1
- package/fontes/depuracao/servidor-depuracao.js +84 -46
- package/fontes/depuracao/servidor-depuracao.js.map +1 -1
- package/fontes/espaco-variaveis.d.ts +1 -1
- package/fontes/espaco-variaveis.js +0 -1
- package/fontes/espaco-variaveis.js.map +1 -1
- package/fontes/estruturas/chamavel.js +1 -1
- package/fontes/estruturas/classe-padrao.d.ts +1 -1
- package/fontes/estruturas/classe-padrao.js.map +1 -1
- package/fontes/estruturas/delegua-classe.d.ts +4 -4
- package/fontes/estruturas/delegua-classe.js +5 -3
- package/fontes/estruturas/delegua-classe.js.map +1 -1
- package/fontes/estruturas/funcao-padrao.d.ts +1 -1
- package/fontes/estruturas/funcao-padrao.js +1 -1
- package/fontes/estruturas/funcao.d.ts +4 -4
- package/fontes/estruturas/funcao.js +9 -4
- package/fontes/estruturas/funcao.js.map +1 -1
- package/fontes/estruturas/index.d.ts +9 -9
- package/fontes/estruturas/metodo-primitiva.d.ts +1 -1
- package/fontes/estruturas/modulo.d.ts +1 -1
- package/fontes/estruturas/modulo.js +1 -1
- package/fontes/estruturas/objeto-delegua-classe.d.ts +2 -2
- package/fontes/estruturas/objeto-delegua-classe.js +2 -2
- package/fontes/estruturas/objeto-delegua-classe.js.map +1 -1
- package/fontes/estruturas/objeto-padrao.js.map +1 -1
- package/fontes/excecoes/erro-em-tempo-de-execucao.d.ts +1 -1
- package/fontes/excecoes/erro-em-tempo-de-execucao.js.map +1 -1
- package/fontes/excecoes/index.d.ts +1 -1
- package/fontes/importador/importador.d.ts +1 -1
- package/fontes/importador/importador.js +3 -2
- package/fontes/importador/importador.js.map +1 -1
- package/fontes/importador/retorno-importador.d.ts +2 -2
- package/fontes/interfaces/avaliador-sintatico-interface.d.ts +3 -5
- package/fontes/interfaces/delegua-interface.d.ts +2 -2
- package/fontes/interfaces/escopo-execucao.d.ts +2 -2
- package/fontes/interfaces/importador-interface.d.ts +1 -1
- package/fontes/interfaces/interpretador-com-depuracao-interface.d.ts +3 -3
- package/fontes/interfaces/interpretador-interface.d.ts +8 -7
- package/fontes/interfaces/lexador-interface.d.ts +4 -4
- package/fontes/interfaces/parametro-interface.d.ts +1 -1
- package/fontes/interfaces/pilha-escopos-execucao-interface.d.ts +5 -5
- package/fontes/interfaces/resolvedor-interface.d.ts +5 -5
- package/fontes/interfaces/retornos/retorno-avaliador-sintatico.d.ts +2 -2
- package/fontes/interfaces/retornos/retorno-execucao-interface.d.ts +1 -1
- package/fontes/interfaces/retornos/retorno-interpretador.d.ts +1 -1
- package/fontes/interfaces/retornos/retorno-lexador.d.ts +3 -3
- package/fontes/interfaces/variavel-interface.d.ts +1 -1
- package/fontes/interpretador/dialetos/egua-classico.d.ts +2 -1
- package/fontes/interpretador/dialetos/egua-classico.js +75 -47
- package/fontes/interpretador/dialetos/egua-classico.js.map +1 -1
- package/fontes/interpretador/dialetos/index.js.map +1 -1
- package/fontes/interpretador/erro-interpretador.d.ts +1 -1
- package/fontes/interpretador/inferenciador.js.map +1 -1
- package/fontes/interpretador/interpretador-com-depuracao.js +5 -3
- package/fontes/interpretador/interpretador-com-depuracao.js.map +1 -1
- package/fontes/interpretador/interpretador.d.ts +10 -4
- package/fontes/interpretador/interpretador.js +57 -47
- package/fontes/interpretador/interpretador.js.map +1 -1
- package/fontes/interpretador/pilha-escopos-execucao.js +16 -5
- package/fontes/interpretador/pilha-escopos-execucao.js.map +1 -1
- package/fontes/lexador/dialetos/index.js.map +1 -1
- package/fontes/lexador/dialetos/lexador-birl.d.ts +25 -0
- package/fontes/lexador/dialetos/lexador-birl.js +75 -0
- package/fontes/lexador/dialetos/lexador-birl.js.map +1 -0
- package/fontes/lexador/dialetos/lexador-egua-classico.js +38 -38
- package/fontes/lexador/dialetos/lexador-egua-classico.js.map +1 -1
- package/fontes/lexador/dialetos/lexador-eguap.d.ts +4 -4
- package/fontes/lexador/dialetos/lexador-eguap.js +50 -44
- package/fontes/lexador/dialetos/lexador-eguap.js.map +1 -1
- package/fontes/lexador/dialetos/lexador-visualg.d.ts +16 -0
- package/fontes/lexador/dialetos/lexador-visualg.js +227 -0
- package/fontes/lexador/dialetos/lexador-visualg.js.map +1 -0
- package/fontes/lexador/dialetos/palavras-reservadas/birl.d.ts +2 -0
- package/fontes/lexador/dialetos/palavras-reservadas/birl.js +4 -0
- package/fontes/lexador/dialetos/palavras-reservadas/birl.js.map +1 -0
- package/fontes/lexador/dialetos/palavras-reservadas/visualg.d.ts +26 -0
- package/fontes/lexador/dialetos/palavras-reservadas/visualg.js +32 -0
- package/fontes/lexador/dialetos/palavras-reservadas/visualg.js.map +1 -0
- package/fontes/lexador/lexador-base-linha-unica.d.ts +33 -0
- package/fontes/lexador/lexador-base-linha-unica.js +92 -0
- package/fontes/lexador/lexador-base-linha-unica.js.map +1 -0
- package/fontes/lexador/lexador.d.ts +3 -3
- package/fontes/lexador/lexador.js +43 -43
- package/fontes/lexador/lexador.js.map +1 -1
- package/fontes/lexador/palavras-reservadas.js +33 -33
- package/fontes/lexador/palavras-reservadas.js.map +1 -1
- package/fontes/lexador/simbolo.d.ts +1 -1
- package/fontes/lexador/simbolo.js +1 -1
- package/fontes/lexador/simbolo.js.map +1 -1
- package/fontes/quebras/index.js.map +1 -1
- package/fontes/resolvedor/dialetos/egua-classico.js +1 -1
- package/fontes/resolvedor/dialetos/egua-classico.js.map +1 -1
- package/fontes/resolvedor/dialetos/index.js.map +1 -1
- package/fontes/resolvedor/erro-resolvedor.d.ts +1 -1
- package/fontes/resolvedor/pilha-escopos.d.ts +1 -1
- package/fontes/resolvedor/pilha-escopos.js +2 -2
- package/fontes/resolvedor/pilha-escopos.js.map +1 -1
- package/fontes/resolvedor/retorno-resolvedor.d.ts +2 -2
- package/fontes/tipos-de-simbolos/birl.d.ts +18 -0
- package/fontes/tipos-de-simbolos/birl.js +21 -0
- package/fontes/tipos-de-simbolos/birl.js.map +1 -0
- package/fontes/tipos-de-simbolos/comum.d.ts +18 -0
- package/fontes/tipos-de-simbolos/comum.js +20 -0
- package/fontes/tipos-de-simbolos/comum.js.map +1 -0
- package/fontes/{tipos-de-simbolos.d.ts → tipos-de-simbolos/delegua.d.ts} +0 -0
- package/fontes/tipos-de-simbolos/delegua.js +78 -0
- package/fontes/tipos-de-simbolos/delegua.js.map +1 -0
- package/fontes/{lexador/dialetos/tipos-de-simbolos-eguap.d.ts → tipos-de-simbolos/eguap.d.ts} +0 -0
- package/fontes/tipos-de-simbolos/eguap.js +74 -0
- package/fontes/tipos-de-simbolos/eguap.js.map +1 -0
- package/fontes/tipos-de-simbolos/visualg.d.ts +47 -0
- package/fontes/tipos-de-simbolos/visualg.js +49 -0
- package/fontes/tipos-de-simbolos/visualg.js.map +1 -0
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/jest.config.js +2 -2
- package/jest.config.js.map +1 -1
- package/package.json +78 -65
- package/testes/avaliador-sintatico.test.js +5 -5
- package/testes/avaliador-sintatico.test.js.map +1 -1
- package/testes/egua-classico/avaliador-sintatico.test.js +4 -1
- package/testes/egua-classico/avaliador-sintatico.test.js.map +1 -1
- package/testes/egua-classico/delegua.test.js.map +1 -1
- package/testes/egua-classico/resolvedor.test.js.map +1 -1
- package/testes/eguap/avaliador-sintatico.test.js +1 -5
- package/testes/eguap/avaliador-sintatico.test.js.map +1 -1
- package/testes/eguap/lexador.test.js +1 -1
- package/testes/eguap/lexador.test.js.map +1 -1
- package/testes/interpretador.test.js +48 -0
- package/testes/interpretador.test.js.map +1 -1
- package/testes/lexador.test.js +45 -45
- package/testes/lexador.test.js.map +1 -1
- package/testes/visualg/avaliador-sintatico.test.d.ts +1 -0
- package/testes/visualg/avaliador-sintatico.test.js +113 -0
- package/testes/visualg/avaliador-sintatico.test.js.map +1 -0
- package/testes/visualg/lexador.test.d.ts +1 -0
- package/testes/visualg/lexador.test.js +67 -0
- package/testes/visualg/lexador.test.js.map +1 -0
- package/fontes/lexador/dialetos/tipos-de-simbolos-eguap.js +0 -74
- package/fontes/lexador/dialetos/tipos-de-simbolos-eguap.js.map +0 -1
- package/fontes/tipos-de-simbolos.js +0 -78
- package/fontes/tipos-de-simbolos.js.map +0 -1
package/fontes/delegua.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AvaliadorSintaticoInterface, DeleguaInterface,
|
|
1
|
+
import { AvaliadorSintaticoInterface, DeleguaInterface, InterpretadorInterface, LexadorInterface, RetornoExecucaoInterface, SimboloInterface } from './interfaces';
|
|
2
2
|
import { ServidorDepuracao } from './depuracao';
|
|
3
3
|
import { ImportadorInterface } from './interfaces/importador-interface';
|
|
4
4
|
import { RetornoImportador } from './importador';
|
|
@@ -15,12 +15,12 @@ export declare class Delegua implements DeleguaInterface {
|
|
|
15
15
|
conteudoArquivosAbertos: {
|
|
16
16
|
[identificador: string]: string[];
|
|
17
17
|
};
|
|
18
|
-
interpretador: InterpretadorInterface
|
|
18
|
+
interpretador: InterpretadorInterface;
|
|
19
19
|
lexador: LexadorInterface;
|
|
20
20
|
avaliadorSintatico: AvaliadorSintaticoInterface;
|
|
21
21
|
importador: ImportadorInterface;
|
|
22
22
|
funcaoDeRetorno: Function;
|
|
23
|
-
modoDepuracao:
|
|
23
|
+
modoDepuracao: boolean;
|
|
24
24
|
servidorDepuracao: ServidorDepuracao;
|
|
25
25
|
constructor(dialeto?: string, performance?: boolean, depurador?: boolean, funcaoDeRetorno?: Function);
|
|
26
26
|
versao(): string;
|
package/fontes/delegua.js
CHANGED
|
@@ -34,7 +34,7 @@ var chalk_1 = __importDefault(require("chalk"));
|
|
|
34
34
|
var lexador_1 = require("./lexador/lexador");
|
|
35
35
|
var avaliador_sintatico_1 = require("./avaliador-sintatico/avaliador-sintatico");
|
|
36
36
|
var interpretador_1 = require("./interpretador/interpretador");
|
|
37
|
-
var
|
|
37
|
+
var delegua_1 = __importDefault(require("./tipos-de-simbolos/delegua"));
|
|
38
38
|
var egua_classico_1 = require("./interpretador/dialetos/egua-classico");
|
|
39
39
|
var lexador_egua_classico_1 = require("./lexador/dialetos/lexador-egua-classico");
|
|
40
40
|
var lexador_eguap_1 = require("./lexador/dialetos/lexador-eguap");
|
|
@@ -44,6 +44,8 @@ var depuracao_1 = require("./depuracao");
|
|
|
44
44
|
var importador_1 = require("./importador");
|
|
45
45
|
var interpretador_com_depuracao_1 = require("./interpretador/interpretador-com-depuracao");
|
|
46
46
|
var dialetos_2 = require("./resolvedor/dialetos");
|
|
47
|
+
var lexador_visualg_1 = require("./lexador/dialetos/lexador-visualg");
|
|
48
|
+
var avaliador_sintatico_visualg_1 = require("./avaliador-sintatico/dialetos/avaliador-sintatico-visualg");
|
|
47
49
|
/**
|
|
48
50
|
* O núcleo da linguagem.
|
|
49
51
|
*
|
|
@@ -63,7 +65,7 @@ var Delegua = /** @class */ (function () {
|
|
|
63
65
|
switch (this.dialeto) {
|
|
64
66
|
case 'egua':
|
|
65
67
|
if (depurador) {
|
|
66
|
-
throw new Error(
|
|
68
|
+
throw new Error('Dialeto ' + this.dialeto + ' não suporta depuração.');
|
|
67
69
|
}
|
|
68
70
|
this.lexador = new lexador_egua_classico_1.LexadorEguaClassico();
|
|
69
71
|
this.avaliadorSintatico = new dialetos_1.AvaliadorSintaticoEguaClassico();
|
|
@@ -75,18 +77,24 @@ var Delegua = /** @class */ (function () {
|
|
|
75
77
|
this.lexador = new lexador_eguap_1.LexadorEguaP();
|
|
76
78
|
this.avaliadorSintatico = new avaliador_sintatico_eguap_1.AvaliadorSintaticoEguaP();
|
|
77
79
|
this.importador = new importador_1.Importador(this.lexador, this.avaliadorSintatico, this.arquivosAbertos, this.conteudoArquivosAbertos, depurador);
|
|
78
|
-
this.interpretador = depurador
|
|
79
|
-
new interpretador_com_depuracao_1.InterpretadorComDepuracao(this.importador, process.cwd(), funcaoDeRetorno)
|
|
80
|
-
new interpretador_1.Interpretador(this.importador, process.cwd(), performance, funcaoDeRetorno);
|
|
80
|
+
this.interpretador = depurador
|
|
81
|
+
? new interpretador_com_depuracao_1.InterpretadorComDepuracao(this.importador, process.cwd(), funcaoDeRetorno)
|
|
82
|
+
: new interpretador_1.Interpretador(this.importador, process.cwd(), performance, funcaoDeRetorno);
|
|
81
83
|
console.log('Usando dialeto: ÉguaP');
|
|
82
84
|
break;
|
|
85
|
+
case 'visualg':
|
|
86
|
+
this.lexador = new lexador_visualg_1.LexadorVisuAlg();
|
|
87
|
+
this.avaliadorSintatico = new avaliador_sintatico_visualg_1.AvaliadorSintaticoVisuAlg();
|
|
88
|
+
this.importador = new importador_1.Importador(this.lexador, this.avaliadorSintatico, this.arquivosAbertos, this.conteudoArquivosAbertos, depurador);
|
|
89
|
+
this.interpretador = new interpretador_1.Interpretador(this.importador, process.cwd(), false, console.log);
|
|
90
|
+
break;
|
|
83
91
|
default:
|
|
84
92
|
this.lexador = new lexador_1.Lexador(performance);
|
|
85
93
|
this.avaliadorSintatico = new avaliador_sintatico_1.AvaliadorSintatico(performance);
|
|
86
94
|
this.importador = new importador_1.Importador(this.lexador, this.avaliadorSintatico, this.arquivosAbertos, this.conteudoArquivosAbertos, depurador);
|
|
87
|
-
this.interpretador = depurador
|
|
88
|
-
new interpretador_com_depuracao_1.InterpretadorComDepuracao(this.importador, process.cwd(), funcaoDeRetorno)
|
|
89
|
-
new interpretador_1.Interpretador(this.importador, process.cwd(), performance, funcaoDeRetorno);
|
|
95
|
+
this.interpretador = depurador
|
|
96
|
+
? new interpretador_com_depuracao_1.InterpretadorComDepuracao(this.importador, process.cwd(), funcaoDeRetorno)
|
|
97
|
+
: new interpretador_1.Interpretador(this.importador, process.cwd(), performance, funcaoDeRetorno);
|
|
90
98
|
console.log('Usando dialeto: padrão');
|
|
91
99
|
break;
|
|
92
100
|
}
|
|
@@ -98,10 +106,10 @@ var Delegua = /** @class */ (function () {
|
|
|
98
106
|
try {
|
|
99
107
|
var manifesto = caminho.resolve('package.json');
|
|
100
108
|
return (JSON.parse(fs.readFileSync(manifesto, { encoding: 'utf8' }))
|
|
101
|
-
.version || '0.
|
|
109
|
+
.version || '0.8');
|
|
102
110
|
}
|
|
103
111
|
catch (error) {
|
|
104
|
-
return '0.
|
|
112
|
+
return '0.8 (desenvolvimento)';
|
|
105
113
|
}
|
|
106
114
|
};
|
|
107
115
|
/**
|
|
@@ -134,12 +142,15 @@ var Delegua = /** @class */ (function () {
|
|
|
134
142
|
Delegua.prototype.executarUmaLinha = function (linha) {
|
|
135
143
|
var retornoLexador = this.lexador.mapear([linha], -1);
|
|
136
144
|
var retornoAvaliadorSintatico = this.avaliadorSintatico.analisar(retornoLexador);
|
|
137
|
-
if (this.afericaoErros({
|
|
145
|
+
if (this.afericaoErros({
|
|
146
|
+
retornoLexador: retornoLexador,
|
|
147
|
+
retornoAvaliadorSintatico: retornoAvaliadorSintatico,
|
|
148
|
+
})) {
|
|
138
149
|
return { resultado: [] };
|
|
139
150
|
}
|
|
140
151
|
return this.executar({
|
|
141
152
|
retornoLexador: retornoLexador,
|
|
142
|
-
retornoAvaliadorSintatico: retornoAvaliadorSintatico
|
|
153
|
+
retornoAvaliadorSintatico: retornoAvaliadorSintatico,
|
|
143
154
|
}, true);
|
|
144
155
|
};
|
|
145
156
|
/**
|
|
@@ -148,7 +159,8 @@ var Delegua = /** @class */ (function () {
|
|
|
148
159
|
Delegua.prototype.iniciarDepuracao = function () {
|
|
149
160
|
this.servidorDepuracao = new depuracao_1.ServidorDepuracao(this);
|
|
150
161
|
this.servidorDepuracao.iniciarServidorDepuracao();
|
|
151
|
-
this.interpretador.finalizacaoDaExecucao =
|
|
162
|
+
this.interpretador.finalizacaoDaExecucao =
|
|
163
|
+
this.finalizarDepuracao.bind(this);
|
|
152
164
|
};
|
|
153
165
|
/**
|
|
154
166
|
* Pede ao servidor de depuração que finalize a execução.
|
|
@@ -174,7 +186,8 @@ var Delegua = /** @class */ (function () {
|
|
|
174
186
|
return true;
|
|
175
187
|
}
|
|
176
188
|
if (retornoImportador.retornoAvaliadorSintatico.erros.length > 0) {
|
|
177
|
-
for (var _b = 0, _c = retornoImportador
|
|
189
|
+
for (var _b = 0, _c = retornoImportador
|
|
190
|
+
.retornoAvaliadorSintatico.erros; _b < _c.length; _b++) {
|
|
178
191
|
var erroAvaliadorSintatico = _c[_b];
|
|
179
192
|
this.erro(erroAvaliadorSintatico.simbolo, erroAvaliadorSintatico.message);
|
|
180
193
|
}
|
|
@@ -194,11 +207,10 @@ var Delegua = /** @class */ (function () {
|
|
|
194
207
|
var errosExecucao = {
|
|
195
208
|
lexador: [],
|
|
196
209
|
avaliadorSintatico: [],
|
|
197
|
-
interpretador: []
|
|
210
|
+
interpretador: [],
|
|
198
211
|
};
|
|
199
212
|
if (this.modoDepuracao) {
|
|
200
|
-
this.interpretador
|
|
201
|
-
.prepararParaDepuracao(retornoImportador.retornoAvaliadorSintatico.declaracoes);
|
|
213
|
+
this.interpretador.prepararParaDepuracao(retornoImportador.retornoAvaliadorSintatico.declaracoes);
|
|
202
214
|
}
|
|
203
215
|
else {
|
|
204
216
|
var erros = this.executar(retornoImportador).erros;
|
|
@@ -226,8 +238,10 @@ var Delegua = /** @class */ (function () {
|
|
|
226
238
|
}
|
|
227
239
|
else {
|
|
228
240
|
var erroEmJavaScript = erroInterpretador;
|
|
229
|
-
console.error(chalk_1.default.red("Erro em JavaScript: ") +
|
|
230
|
-
|
|
241
|
+
console.error(chalk_1.default.red("Erro em JavaScript: ") +
|
|
242
|
+
"".concat(erroEmJavaScript.message));
|
|
243
|
+
console.error(chalk_1.default.red("Pilha de execu\u00E7\u00E3o: ") +
|
|
244
|
+
"".concat(erroEmJavaScript.stack));
|
|
231
245
|
}
|
|
232
246
|
}
|
|
233
247
|
}
|
|
@@ -246,7 +260,7 @@ var Delegua = /** @class */ (function () {
|
|
|
246
260
|
console.error(chalk_1.default.red("[Linha: ".concat(linha, "]")) + " Erro".concat(onde, ": ").concat(mensagem));
|
|
247
261
|
};
|
|
248
262
|
Delegua.prototype.erro = function (simbolo, mensagemDeErro) {
|
|
249
|
-
if (simbolo.tipo ===
|
|
263
|
+
if (simbolo.tipo === delegua_1.default.EOF) {
|
|
250
264
|
this.reportar(Number(simbolo.linha), ' no final', mensagemDeErro);
|
|
251
265
|
}
|
|
252
266
|
else {
|
|
@@ -261,10 +275,12 @@ var Delegua = /** @class */ (function () {
|
|
|
261
275
|
chalk.red(`Erro: [Arquivo: ${this.nomeArquivo}] [Linha: ${erro.simbolo.linha}]`) + ` ${erro.mensagem}`
|
|
262
276
|
);
|
|
263
277
|
else */
|
|
264
|
-
console.error(chalk_1.default.red("Erro: [Linha: ".concat(erro.simbolo.linha, "]")) +
|
|
278
|
+
console.error(chalk_1.default.red("Erro: [Linha: ".concat(erro.simbolo.linha, "]")) +
|
|
279
|
+
" ".concat(erro.mensagem));
|
|
265
280
|
}
|
|
266
281
|
else {
|
|
267
|
-
console.error(chalk_1.default.red("Erro: [Linha: ".concat(erro.linha || 0, "]")) +
|
|
282
|
+
console.error(chalk_1.default.red("Erro: [Linha: ".concat(erro.linha || 0, "]")) +
|
|
283
|
+
" ".concat(erro.mensagem));
|
|
268
284
|
}
|
|
269
285
|
};
|
|
270
286
|
return Delegua;
|
package/fontes/delegua.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"delegua.js","sourceRoot":"","sources":["../../fontes/delegua.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,qCAAyB;AACzB,4CAAgC;AAChC,iDAAqC;AACrC,gDAA0B;AAE1B,6CAA4C;AAC5C,iFAA+E;AAC/E,+DAA8D;AAC9D,
|
|
1
|
+
{"version":3,"file":"delegua.js","sourceRoot":"","sources":["../../fontes/delegua.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,qCAAyB;AACzB,4CAAgC;AAChC,iDAAqC;AACrC,gDAA0B;AAE1B,6CAA4C;AAC5C,iFAA+E;AAC/E,+DAA8D;AAC9D,wEAA0D;AAY1D,wEAAmF;AACnF,kFAA+E;AAC/E,kEAAgE;AAChE,sGAAmG;AACnG,2DAAgF;AAChF,yCAAgD;AAGhD,2CAA6D;AAC7D,2FAAwF;AACxF,kDAA+D;AAC/D,sEAAoE;AACpE,0GAAuG;AAEvG;;;;GAIG;AACH;IAcI,iBACI,OAAmB,EACnB,WAAmB,EACnB,SAAiB,EACjB,eAAgC;QAHhC,wBAAA,EAAA,mBAAmB;QACnB,4BAAA,EAAA,mBAAmB;QACnB,0BAAA,EAAA,iBAAiB;QACjB,gCAAA,EAAA,sBAAgC;QAEhC,IAAI,CAAC,eAAe,GAAG,EAAE,CAAC;QAC1B,IAAI,CAAC,uBAAuB,GAAG,EAAE,CAAC;QAElC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,eAAe,GAAG,eAAe,IAAI,OAAO,CAAC,GAAG,CAAC;QACtD,IAAI,CAAC,aAAa,GAAG,SAAS,CAAC;QAE/B,QAAQ,IAAI,CAAC,OAAO,EAAE;YAClB,KAAK,MAAM;gBACP,IAAI,SAAS,EAAE;oBACX,MAAM,IAAI,KAAK,CACX,UAAU,GAAG,IAAI,CAAC,OAAO,GAAG,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C,2DAA2D;YAC3D;;;;mBAIO;YACP,OAAO,CAAC,KAAK,CACT,eAAK,CAAC,GAAG,CAAC,wBAAiB,IAAI,CAAC,OAAO,CAAC,KAAK,MAAG,CAAC;gBAC7C,WAAI,IAAI,CAAC,QAAQ,CAAE,CAC1B,CAAC;SACL;aAAM;YACH,OAAO,CAAC,KAAK,CACT,eAAK,CAAC,GAAG,CAAC,wBAAiB,IAAI,CAAC,KAAK,IAAI,CAAC,MAAG,CAAC;gBAC1C,WAAI,IAAI,CAAC,QAAQ,CAAE,CAC1B,CAAC;SACL;IACL,CAAC;IACL,cAAC;AAAD,CAAC,AAxWD,IAwWC;AAxWY,0BAAO"}
|
|
@@ -16,10 +16,13 @@ function cyrb53(str, seed) {
|
|
|
16
16
|
h1 = Math.imul(h1 ^ ch, 2654435761);
|
|
17
17
|
h2 = Math.imul(h2 ^ ch, 1597334677);
|
|
18
18
|
}
|
|
19
|
-
h1 =
|
|
20
|
-
|
|
19
|
+
h1 =
|
|
20
|
+
Math.imul(h1 ^ (h1 >>> 16), 2246822507) ^
|
|
21
|
+
Math.imul(h2 ^ (h2 >>> 13), 3266489909);
|
|
22
|
+
h2 =
|
|
23
|
+
Math.imul(h2 ^ (h2 >>> 16), 2246822507) ^
|
|
24
|
+
Math.imul(h1 ^ (h1 >>> 13), 3266489909);
|
|
21
25
|
return 4294967296 * (2097151 & h2) + (h1 >>> 0);
|
|
22
26
|
}
|
|
23
27
|
exports.default = cyrb53;
|
|
24
|
-
;
|
|
25
28
|
//# sourceMappingURL=cyrb53.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cyrb53.js","sourceRoot":"","sources":["../../../fontes/depuracao/cyrb53.ts"],"names":[],"mappings":";;AAAA;;;;;;;GAOG;AACH,SAAwB,MAAM,CAAC,GAAW,EAAE,IAAQ;IAAR,qBAAA,EAAA,QAAQ;IAChD,IAAI,EAAE,GAAG,UAAU,GAAG,IAAI,
|
|
1
|
+
{"version":3,"file":"cyrb53.js","sourceRoot":"","sources":["../../../fontes/depuracao/cyrb53.ts"],"names":[],"mappings":";;AAAA;;;;;;;GAOG;AACH,SAAwB,MAAM,CAAC,GAAW,EAAE,IAAQ;IAAR,qBAAA,EAAA,QAAQ;IAChD,IAAI,EAAE,GAAG,UAAU,GAAG,IAAI,EACtB,EAAE,GAAG,UAAU,GAAG,IAAI,CAAC;IAC3B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,EAAE,SAAQ,EAAE,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;QAC7C,EAAE,GAAG,GAAG,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;QACvB,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,EAAE,EAAE,UAAU,CAAC,CAAC;QACpC,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,EAAE,EAAE,UAAU,CAAC,CAAC;KACvC;IACD,EAAE;QACE,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC;YACvC,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC,CAAC;IAC5C,EAAE;QACE,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC;YACvC,IAAI,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,UAAU,CAAC,CAAC;IAC5C,OAAO,UAAU,GAAG,CAAC,OAAO,GAAG,EAAE,CAAC,GAAG,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC;AACpD,CAAC;AAfD,yBAeC"}
|
|
@@ -38,14 +38,15 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
38
38
|
conexao.write("[adicionar-ponto-parada]: Arquivo '".concat(caminhoArquivo, "' n\u00E3o encontrado\n"));
|
|
39
39
|
return { sucesso: false };
|
|
40
40
|
}
|
|
41
|
-
if (_this.instanciaDelegua.conteudoArquivosAbertos[hashArquivo].length <
|
|
41
|
+
if (_this.instanciaDelegua.conteudoArquivosAbertos[hashArquivo].length <
|
|
42
|
+
linha) {
|
|
42
43
|
conexao.write("[adicionar-ponto-parada]: Linha ".concat(linha, " n\u00E3o existente em arquivo '").concat(caminhoArquivo, "'\n"));
|
|
43
44
|
return { sucesso: false };
|
|
44
45
|
}
|
|
45
46
|
return { sucesso: true, hashArquivo: hashArquivo, linha: linha };
|
|
46
47
|
};
|
|
47
48
|
this.comandoAdentrarEscopo = function (conexao) {
|
|
48
|
-
var linhasResposta =
|
|
49
|
+
var linhasResposta = '';
|
|
49
50
|
linhasResposta += "Recebido comando 'adentrar-escopo'\n";
|
|
50
51
|
linhasResposta += '--- adentrar-escopo-resposta ---\n';
|
|
51
52
|
_this.interpretador.comandoAdentrarEscopo = true;
|
|
@@ -63,18 +64,19 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
63
64
|
if (validacaoPontoParada.sucesso) {
|
|
64
65
|
_this.interpretador.pontosParada.push({
|
|
65
66
|
hashArquivo: validacaoPontoParada.hashArquivo,
|
|
66
|
-
linha: validacaoPontoParada.linha
|
|
67
|
+
linha: validacaoPontoParada.linha,
|
|
67
68
|
});
|
|
68
69
|
}
|
|
69
70
|
};
|
|
70
71
|
this.comandoAvaliar = function (comando, conexao) {
|
|
71
|
-
var linhasResposta =
|
|
72
|
+
var linhasResposta = '';
|
|
72
73
|
comando.shift();
|
|
73
74
|
var expressaoAvaliar = comando.join(' ');
|
|
74
75
|
var retornoInterpretacao;
|
|
75
76
|
var textoInterpretacao;
|
|
76
77
|
try {
|
|
77
|
-
retornoInterpretacao =
|
|
78
|
+
retornoInterpretacao =
|
|
79
|
+
_this.instanciaDelegua.executarUmaLinha(expressaoAvaliar);
|
|
78
80
|
textoInterpretacao = retornoInterpretacao.resultado;
|
|
79
81
|
}
|
|
80
82
|
catch (erro) {
|
|
@@ -87,7 +89,7 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
87
89
|
conexao.write(linhasResposta);
|
|
88
90
|
};
|
|
89
91
|
this.comandoContinuar = function (conexao) {
|
|
90
|
-
var linhasResposta =
|
|
92
|
+
var linhasResposta = '';
|
|
91
93
|
linhasResposta += "Recebido comando 'continuar'\n";
|
|
92
94
|
_this.interpretador.pontoDeParadaAtivo = false;
|
|
93
95
|
_this.interpretador.continuarInterpretacao();
|
|
@@ -95,19 +97,27 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
95
97
|
conexao.write(linhasResposta);
|
|
96
98
|
};
|
|
97
99
|
this.comandoPilhaExecucao = function (conexao) {
|
|
98
|
-
var linhasResposta =
|
|
100
|
+
var linhasResposta = '';
|
|
99
101
|
linhasResposta += "Recebido comando 'pilha-execucao'\n";
|
|
100
102
|
var pilhaEscoposExecucao = _this.interpretador.pilhaEscoposExecucao;
|
|
101
103
|
linhasResposta += '--- pilha-execucao-resposta ---\n';
|
|
102
104
|
try {
|
|
103
105
|
for (var i = pilhaEscoposExecucao.pilha.length - 1; i > 0; i--) {
|
|
104
106
|
var elementoPilha = pilhaEscoposExecucao.pilha[i];
|
|
105
|
-
var posicaoDeclaracaoAtual = elementoPilha.declaracaoAtual >=
|
|
107
|
+
var posicaoDeclaracaoAtual = elementoPilha.declaracaoAtual >=
|
|
108
|
+
elementoPilha.declaracoes.length
|
|
109
|
+
? elementoPilha.declaracoes.length - 1
|
|
110
|
+
: elementoPilha.declaracaoAtual;
|
|
106
111
|
var declaracaoAtual = elementoPilha.declaracoes[posicaoDeclaracaoAtual];
|
|
107
|
-
linhasResposta +=
|
|
108
|
-
_this.instanciaDelegua.
|
|
109
|
-
|
|
110
|
-
|
|
112
|
+
linhasResposta +=
|
|
113
|
+
_this.instanciaDelegua.conteudoArquivosAbertos[declaracaoAtual.hashArquivo][declaracaoAtual.linha - 1].trim() +
|
|
114
|
+
' --- ' +
|
|
115
|
+
_this.instanciaDelegua.arquivosAbertos[declaracaoAtual.hashArquivo] +
|
|
116
|
+
'::' +
|
|
117
|
+
declaracaoAtual.assinaturaMetodo +
|
|
118
|
+
'::' +
|
|
119
|
+
declaracaoAtual.linha +
|
|
120
|
+
'\n';
|
|
111
121
|
}
|
|
112
122
|
linhasResposta += '--- fim-pilha-execucao-resposta ---\n';
|
|
113
123
|
conexao.write(linhasResposta);
|
|
@@ -117,17 +127,20 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
117
127
|
}
|
|
118
128
|
};
|
|
119
129
|
this.comandoPontosParada = function (conexao) {
|
|
120
|
-
var linhasResposta =
|
|
130
|
+
var linhasResposta = '';
|
|
121
131
|
linhasResposta += "Recebido comando 'pontos-parada'\n";
|
|
122
132
|
for (var _i = 0, _a = _this.interpretador.pontosParada; _i < _a.length; _i++) {
|
|
123
133
|
var pontoParada = _a[_i];
|
|
124
|
-
linhasResposta +=
|
|
125
|
-
pontoParada.
|
|
134
|
+
linhasResposta +=
|
|
135
|
+
_this.instanciaDelegua.arquivosAbertos[pontoParada.hashArquivo] +
|
|
136
|
+
': ' +
|
|
137
|
+
pontoParada.linha +
|
|
138
|
+
'\n';
|
|
126
139
|
}
|
|
127
140
|
conexao.write(linhasResposta);
|
|
128
141
|
};
|
|
129
142
|
this.comandoProximo = function (conexao) {
|
|
130
|
-
var linhasResposta =
|
|
143
|
+
var linhasResposta = '';
|
|
131
144
|
linhasResposta += "Recebido comando 'proximo'\n";
|
|
132
145
|
linhasResposta += '--- proximo-resposta ---\n';
|
|
133
146
|
_this.interpretador.comandoProximo = true;
|
|
@@ -137,7 +150,7 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
137
150
|
conexao.write(linhasResposta);
|
|
138
151
|
};
|
|
139
152
|
this.comandoRemoverPontoParada = function (comando, conexao) {
|
|
140
|
-
var linhasResposta =
|
|
153
|
+
var linhasResposta = '';
|
|
141
154
|
linhasResposta += "Recebido comando 'remover-ponto-parada'\n";
|
|
142
155
|
if (comando.length < 3) {
|
|
143
156
|
linhasResposta += "[adicionar-ponto-parada]: Formato: adicionar-ponto-parada /caminho/do/arquivo.egua 1\n";
|
|
@@ -146,10 +159,11 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
146
159
|
}
|
|
147
160
|
var validacaoPontoParada = _this.validarPontoParada(comando[1], parseInt(comando[2]), conexao);
|
|
148
161
|
if (validacaoPontoParada.sucesso) {
|
|
149
|
-
_this.interpretador.pontosParada =
|
|
150
|
-
|
|
151
|
-
p.
|
|
152
|
-
|
|
162
|
+
_this.interpretador.pontosParada =
|
|
163
|
+
_this.interpretador.pontosParada.filter(function (p) {
|
|
164
|
+
return p.hashArquivo !== validacaoPontoParada.hashArquivo &&
|
|
165
|
+
p.linha !== validacaoPontoParada.linha;
|
|
166
|
+
});
|
|
153
167
|
}
|
|
154
168
|
};
|
|
155
169
|
this.comandoSairEscopo = function (conexao) {
|
|
@@ -158,16 +172,23 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
158
172
|
_this.interpretador.proximoESair();
|
|
159
173
|
};
|
|
160
174
|
this.comandoVariaveis = function (conexao) {
|
|
161
|
-
var linhasResposta =
|
|
162
|
-
linhasResposta +=
|
|
175
|
+
var linhasResposta = '';
|
|
176
|
+
linhasResposta +=
|
|
177
|
+
"Recebido comando 'variaveis'. Enviando variáveis do escopo atual\n";
|
|
163
178
|
var todasVariaveis = _this.interpretador.pilhaEscoposExecucao.obterTodasVariaveis([]);
|
|
164
179
|
linhasResposta += '--- variaveis-resposta ---\n';
|
|
165
180
|
for (var _i = 0, todasVariaveis_1 = todasVariaveis; _i < todasVariaveis_1.length; _i++) {
|
|
166
181
|
var grupoVariavel = todasVariaveis_1[_i];
|
|
167
182
|
for (var _a = 0, _b = Object.entries(grupoVariavel); _a < _b.length; _a++) {
|
|
168
183
|
var _c = _b[_a], nomeVariavel = _c[0], valor = _c[1];
|
|
169
|
-
if (
|
|
170
|
-
linhasResposta +=
|
|
184
|
+
if (valor) {
|
|
185
|
+
linhasResposta +=
|
|
186
|
+
nomeVariavel +
|
|
187
|
+
' :: ' +
|
|
188
|
+
Object.getPrototypeOf(valor).constructor.name +
|
|
189
|
+
' :: ' +
|
|
190
|
+
valor +
|
|
191
|
+
'\n';
|
|
171
192
|
}
|
|
172
193
|
}
|
|
173
194
|
}
|
|
@@ -180,72 +201,87 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
180
201
|
*/
|
|
181
202
|
this.operarConexao = function (conexao) {
|
|
182
203
|
var enderecoRemoto = conexao.remoteAddress + ':' + conexao.remotePort;
|
|
183
|
-
process.stdout.write('\n[Depurador] Nova conexão de cliente de ' +
|
|
204
|
+
process.stdout.write('\n[Depurador] Nova conexão de cliente de ' +
|
|
205
|
+
enderecoRemoto +
|
|
206
|
+
'\ndelegua> ');
|
|
184
207
|
conexao.setEncoding('utf8');
|
|
185
208
|
_this.conexoes[_this.contadorConexoes++] = conexao;
|
|
186
209
|
// Aqui, dados pode ter uma série de comandos, sendo um por linha.
|
|
187
210
|
var aoReceberDados = function (dados) {
|
|
188
211
|
var comandos = String(dados).split('\n');
|
|
189
|
-
process.stdout.write('\n[Depurador] Dados da conexão vindos de ' +
|
|
212
|
+
process.stdout.write('\n[Depurador] Dados da conexão vindos de ' +
|
|
213
|
+
enderecoRemoto +
|
|
214
|
+
': ' +
|
|
215
|
+
comandos +
|
|
216
|
+
'\ndelegua> ');
|
|
190
217
|
for (var _i = 0, comandos_1 = comandos; _i < comandos_1.length; _i++) {
|
|
191
218
|
var comando = comandos_1[_i];
|
|
192
219
|
var partesComando = comando.split(' ');
|
|
193
220
|
switch (partesComando[0]) {
|
|
194
|
-
case
|
|
221
|
+
case 'adentrar-escopo':
|
|
195
222
|
_this.comandoAdentrarEscopo(conexao);
|
|
196
223
|
break;
|
|
197
|
-
case
|
|
224
|
+
case 'adicionar-ponto-parada':
|
|
198
225
|
_this.comandoAdicionarPontoParada(partesComando, conexao);
|
|
199
226
|
break;
|
|
200
|
-
case
|
|
227
|
+
case 'avaliar':
|
|
201
228
|
_this.comandoAvaliar(partesComando, conexao);
|
|
202
229
|
break;
|
|
203
|
-
case
|
|
230
|
+
case 'continuar':
|
|
204
231
|
_this.comandoContinuar(conexao);
|
|
205
232
|
break;
|
|
206
|
-
case
|
|
233
|
+
case 'pilha-execucao':
|
|
207
234
|
_this.comandoPilhaExecucao(conexao);
|
|
208
235
|
break;
|
|
209
|
-
case
|
|
236
|
+
case 'pontos-parada':
|
|
210
237
|
_this.comandoPontosParada(conexao);
|
|
211
238
|
break;
|
|
212
|
-
case
|
|
239
|
+
case 'proximo':
|
|
213
240
|
_this.comandoProximo(conexao);
|
|
214
241
|
break;
|
|
215
|
-
case
|
|
242
|
+
case 'remover-ponto-parada':
|
|
216
243
|
_this.comandoRemoverPontoParada(partesComando, conexao);
|
|
217
244
|
break;
|
|
218
|
-
case
|
|
245
|
+
case 'sair-escopo':
|
|
219
246
|
_this.comandoSairEscopo(conexao);
|
|
220
247
|
break;
|
|
221
|
-
case
|
|
248
|
+
case 'tchau':
|
|
222
249
|
conexao.write("Recebido comando 'tchau'. Conexão será encerrada\n");
|
|
223
250
|
_this.finalizarServidorDepuracao();
|
|
224
251
|
return;
|
|
225
|
-
case
|
|
252
|
+
case 'variaveis':
|
|
226
253
|
_this.comandoVariaveis(conexao);
|
|
227
254
|
break;
|
|
228
255
|
}
|
|
229
256
|
}
|
|
230
257
|
};
|
|
231
258
|
var aoFecharConexao = function () {
|
|
232
|
-
process.stdout.write('\n[Depurador] Conexão de ' +
|
|
259
|
+
process.stdout.write('\n[Depurador] Conexão de ' +
|
|
260
|
+
enderecoRemoto +
|
|
261
|
+
' fechada\ndelegua> ');
|
|
233
262
|
};
|
|
234
263
|
var aoObterErro = function (erro) {
|
|
235
|
-
process.stdout.write('\n[Depurador] Conexão ' +
|
|
264
|
+
process.stdout.write('\n[Depurador] Conexão ' +
|
|
265
|
+
enderecoRemoto +
|
|
266
|
+
' com erro: ' +
|
|
267
|
+
erro.message +
|
|
268
|
+
'\ndelegua> ');
|
|
236
269
|
};
|
|
237
|
-
// `.bind()` é necessário aqui para que os eventos não usem net.Socket ou net.Server como o `this`,
|
|
270
|
+
// `.bind()` é necessário aqui para que os eventos não usem net.Socket ou net.Server como o `this`,
|
|
238
271
|
// como acontece normalmente se o `.bind()` não é chamado.
|
|
239
272
|
conexao.on('data', aoReceberDados.bind(_this));
|
|
240
273
|
conexao.once('close', aoFecharConexao.bind(_this));
|
|
241
274
|
conexao.on('error', aoObterErro.bind(_this));
|
|
242
275
|
};
|
|
243
276
|
this.instanciaDelegua = _instanciaDelegua;
|
|
244
|
-
this.instanciaDelegua.funcaoDeRetorno =
|
|
245
|
-
|
|
246
|
-
this.interpretador
|
|
277
|
+
this.instanciaDelegua.funcaoDeRetorno =
|
|
278
|
+
this.escreverSaidaParaTodosClientes.bind(this);
|
|
279
|
+
this.interpretador = this.instanciaDelegua
|
|
280
|
+
.interpretador;
|
|
281
|
+
this.interpretador.funcaoDeRetorno =
|
|
282
|
+
this.escreverSaidaParaTodosClientes.bind(this);
|
|
247
283
|
// Isso é só um exemplo de definição de ponto de parada para testar
|
|
248
|
-
// `Interpretador.executar()`.
|
|
284
|
+
// `Interpretador.executar()`.
|
|
249
285
|
// Deve ser removido num futuro próximo.
|
|
250
286
|
/* (this.instanciaDelegua.interpretador as InterpretadorComDepuracaoInterface).pontosParada.push({
|
|
251
287
|
hashArquivo: cyrb53("D:\\GitHub\\delegua\\testes\\exemplos\\index.delegua"),
|
|
@@ -266,7 +302,9 @@ var ServidorDepuracao = /** @class */ (function () {
|
|
|
266
302
|
ServidorDepuracao.prototype.escreverSaidaParaTodosClientes = function (mensagem) {
|
|
267
303
|
var _this = this;
|
|
268
304
|
Object.keys(this.conexoes).forEach(function (chave) {
|
|
269
|
-
_this.conexoes[chave].write('Enviando mensagem de saída\n--- mensagem-saida ---\n' +
|
|
305
|
+
_this.conexoes[chave].write('Enviando mensagem de saída\n--- mensagem-saida ---\n' +
|
|
306
|
+
mensagem +
|
|
307
|
+
'\n');
|
|
270
308
|
});
|
|
271
309
|
};
|
|
272
310
|
ServidorDepuracao.prototype.finalizarServidorDepuracao = function () {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"servidor-depuracao.js","sourceRoot":"","sources":["../../../fontes/depuracao/servidor-depuracao.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAA2B;
|
|
1
|
+
{"version":3,"file":"servidor-depuracao.js","sourceRoot":"","sources":["../../../fontes/depuracao/servidor-depuracao.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAA2B;AAS3B,oDAA8B;AAG9B;IAOI,2BAAY,iBAAmC;QAA/C,iBAoBC;QAED,uBAAkB,GAAG,UACjB,cAAsB,EACtB,KAAa,EACb,OAAmB;YAEnB,IAAM,WAAW,GAAG,IAAA,gBAAM,EAAC,cAAc,CAAC,WAAW,EAAE,CAAC,CAAC;YACzD,IACI,CAAC,KAAI,CAAC,gBAAgB,CAAC,eAAe,CAAC,cAAc,CAAC,WAAW,CAAC,EACpE;gBACE,OAAO,CAAC,KAAK,CACT,6CAAsC,cAAc,4BAAoB,CAC3E,CAAC;gBACF,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;aAC7B;YAED,IACI,KAAI,CAAC,gBAAgB,CAAC,uBAAuB,CAAC,WAAW,CAAC,CAAC,MAAM;gBACjE,KAAK,EACP;gBACE,OAAO,CAAC,KAAK,CACT,0CAAmC,KAAK,6CAA8B,cAAc,QAAK,CAC5F,CAAC;gBACF,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;aAC7B;YAED,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,WAAW,aAAA,EAAE,KAAK,OAAA,EAAE,CAAC;QACjD,CAAC,CAAC;QAEF,0BAAqB,GAAG,UAAC,OAAmB;YACxC,IAAI,cAAc,GAAG,EAAE,CAAC;Y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espaco-variaveis.ts"],"names":[],"mappings":";;;AAEA;IAGI;QACI,IAAI,CAAC,OAAO,GAAG,EAAE,CAAC;IACtB,CAAC;IACL,sBAAC;AAAD,CAAC,AAND,IAMC;AANY,0CAAe
|
|
1
|
+
{"version":3,"file":"espaco-variaveis.js","sourceRoot":"","sources":["../../fontes/espaco-variaveis.ts"],"names":[],"mappings":";;;AAEA;IAGI;QACI,IAAI,CAAC,OAAO,GAAG,EAAE,CAAC;IACtB,CAAC;IACL,sBAAC;AAAD,CAAC,AAND,IAMC;AANY,0CAAe"}
|
|
@@ -8,7 +8,7 @@ var Chamavel = /** @class */ (function () {
|
|
|
8
8
|
return this.valorAridade;
|
|
9
9
|
};
|
|
10
10
|
Chamavel.prototype.chamar = function (interpretador, argumentos, simbolo) {
|
|
11
|
-
throw new Error(
|
|
11
|
+
throw new Error('Este método não deveria ser chamado.');
|
|
12
12
|
};
|
|
13
13
|
return Chamavel;
|
|
14
14
|
}());
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"classe-padrao.js","sourceRoot":"","sources":["../../../fontes/estruturas/classe-padrao.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,uCAAsC;AACtC,iDAA+C;AAE/C;;GAEG;AACH;IAAkC,gCAAQ;IAKtC,sBAAY,IAAY,EAAE,cAAwB;QAAlD,YACI,iBAAO,SAIV;QAHG,KAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,KAAI,CAAC,cAAc,GAAG,cAAc,CAAC;QACrC,KAAI,CAAC,OAAO,GAAG,EAAE,CAAC;;IACtB,CAAC;IAED,sCAAe,GAAf,UAAgB,IAAY;QACxB,IAAI,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,EAAE;YACnC,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;SAC7B;QAED,OAAO,SAAS,CAAC;IACrB,CAAC;IAED,gCAAS,GAAT;QACI,OAAO,8BAAkB,IAAI,CA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