firefly-compiler 0.6.21 → 0.6.24
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/.vscode/settings.json +1 -1
- package/compiler/Inference.ff +17 -1
- package/compiler/LspHook.ff +15 -5
- package/core/Ordering.ff +1 -1
- package/experimental/inceptron/Run.ff +47 -0
- package/experimental/mattis/Tree.ff +44 -0
- package/experimental/tests/TestListOrdering.ff +7 -0
- package/experimental/tests/TestOrder.ff +4 -0
- package/experimental/tests/TestSql.ff +18 -0
- package/lsp/.firefly/package.ff +1 -0
- package/lsp/CompletionHandler.ff +112 -6
- package/lsp/Handler.ff +205 -7
- package/lsp/LanguageServer.ff +5 -0
- package/lsp/SemanticTokenTypes.ff +62 -0
- package/lsp/Sql.ff +1395 -0
- package/lsp/SqlStatement.ff +34 -0
- package/lsp/SqlSuggestion.ff +295 -0
- package/output/js/ff/compiler/Builder.mjs +2 -2
- package/output/js/ff/compiler/Builder.mjs.map +1 -1
- package/output/js/ff/compiler/Dependencies.mjs +2 -2
- package/output/js/ff/compiler/Dependencies.mjs.map +1 -1
- package/output/js/ff/compiler/Inference.mjs +36 -16
- package/output/js/ff/compiler/Inference.mjs.map +4 -2
- package/output/js/ff/compiler/LspHook.mjs +10 -10
- package/output/js/ff/compiler/LspHook.mjs.map +4 -3
- package/output/js/ff/compiler/Main.mjs +4 -4
- package/output/js/ff/compiler/Main.mjs.map +1 -1
- package/output/js/ff/core/Ordering.mjs +2 -2
- package/output/js/ff/core/Ordering.mjs.map +1 -1
- package/package.json +1 -1
- package/postgresql/Pg.ff +49 -26
- package/vscode/client/src/extension.ts +5 -0
- package/vscode/package.json +7 -1
|
@@ -1437,17 +1437,27 @@ ff_compiler_Unification.Unification_unify(self_.unification_, term_.at_, expecte
|
|
|
1437
1437
|
ff_compiler_Unification.Unification_unify(self_.unification_, term_.at_, selfParameter_.valueType_, recordType_);
|
|
1438
1438
|
const arguments_ = ff_compiler_Inference.Inference_inferArguments(self_, term_.at_, name_, environment_, ff_core_List.List_dropFirst(signature_.parameters_, 1), e_.arguments_);
|
|
1439
1439
|
ff_compiler_Unification.Unification_affect(self_.unification_, term_.at_, signature_.effect_, environment_.effect_);
|
|
1440
|
-
{
|
|
1441
|
-
const _1 = e_;
|
|
1442
|
-
{
|
|
1443
|
-
const _c = _1;
|
|
1440
|
+
const result_ = (((_c) => {
|
|
1444
1441
|
return ff_compiler_Syntax.ECall(_c.at_, ff_compiler_Syntax.StaticCall(name_, tailCall_, false), signature_.effect_, ff_core_List.List_map(instantiation_, ((_w1) => {
|
|
1445
1442
|
return _w1.second_
|
|
1446
1443
|
})), [selfArgument_, ...arguments_], _c.dictionaries_)
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1444
|
+
}))(e_);
|
|
1445
|
+
if(self_.lspHook_.sql_) {
|
|
1446
|
+
if((name_ === "ff:postgresql/Pg.PgConnection_statement")) {
|
|
1447
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
1448
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_map")) {
|
|
1449
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
1450
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_each")) {
|
|
1451
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
1452
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_any")) {
|
|
1453
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
1454
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_all")) {
|
|
1455
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
1456
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_run")) {
|
|
1457
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
1458
|
+
} else {}
|
|
1459
|
+
};
|
|
1460
|
+
return result_
|
|
1451
1461
|
}
|
|
1452
1462
|
{
|
|
1453
1463
|
return ff_compiler_Inference.fail_(term_.at_, "Call expected")
|
|
@@ -3354,17 +3364,27 @@ ff_compiler_Unification.Unification_unify(self_.unification_, term_.at_, expecte
|
|
|
3354
3364
|
ff_compiler_Unification.Unification_unify(self_.unification_, term_.at_, selfParameter_.valueType_, recordType_);
|
|
3355
3365
|
const arguments_ = ff_compiler_Inference.Inference_inferArguments(self_, term_.at_, name_, environment_, ff_core_List.List_dropFirst(signature_.parameters_, 1), e_.arguments_);
|
|
3356
3366
|
ff_compiler_Unification.Unification_affect(self_.unification_, term_.at_, signature_.effect_, environment_.effect_);
|
|
3357
|
-
{
|
|
3358
|
-
const _1 = e_;
|
|
3359
|
-
{
|
|
3360
|
-
const _c = _1;
|
|
3367
|
+
const result_ = (((_c) => {
|
|
3361
3368
|
return ff_compiler_Syntax.ECall(_c.at_, ff_compiler_Syntax.StaticCall(name_, tailCall_, false), signature_.effect_, ff_core_List.List_map(instantiation_, ((_w1) => {
|
|
3362
3369
|
return _w1.second_
|
|
3363
3370
|
})), [selfArgument_, ...arguments_], _c.dictionaries_)
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
|
|
3367
|
-
|
|
3371
|
+
}))(e_);
|
|
3372
|
+
if(self_.lspHook_.sql_) {
|
|
3373
|
+
if((name_ === "ff:postgresql/Pg.PgConnection_statement")) {
|
|
3374
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
3375
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_map")) {
|
|
3376
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
3377
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_each")) {
|
|
3378
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
3379
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_any")) {
|
|
3380
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
3381
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_all")) {
|
|
3382
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
3383
|
+
} else if((name_ === "ff:postgresql/Pg.PgStatement_run")) {
|
|
3384
|
+
self_.lspHook_.sqlStrings_.array.push(result_)
|
|
3385
|
+
} else {}
|
|
3386
|
+
};
|
|
3387
|
+
return result_
|
|
3368
3388
|
}
|
|
3369
3389
|
{
|
|
3370
3390
|
return ff_compiler_Inference.fail_(term_.at_, "Call expected")
|