Fedor Isakov
f3b16186e6
Fix build scripts and regenerate.
2020-05-09 10:54:18 +02:00
Fedor Isakov
acd6234415
Force save all.
2020-05-09 10:54:18 +02:00
Fedor Isakov
c4fc687f76
Refactor and simplify code in AspectClique. Write tests.
...
Treat a language and its sidekick (if any) as a single vertex.
Add all extended languages to the pool before building the graph.
Drop dubious invariant check.
Fix the second pass in findAspectCliques ingnoring the fact
that there might be leafs without aspects.
2020-05-09 10:53:40 +02:00
Fedor Isakov
5bac140e61
Drop unnecessary test languages.
2020-05-07 10:23:04 +02:00
Fedor Isakov
f2bcaffccc
Revert "Upd coderules buildscript, regen build.xml"
...
This reverts commit 6b826334
2020-05-07 10:18:16 +02:00
Fedor Isakov
65429c800e
Test for AspectClique. Use test model instead of real languages.
2020-05-07 10:16:55 +02:00
Fedor Isakov
4744081e36
Refactor AspectLookup and related interfaces for testability.
...
Simplify interfaces, abstract away the direct dependency
on LanguageRutime, make the code in AspectClique testable.
2020-05-07 10:16:53 +02:00
Fedor Isakov
aa2785cc7a
Document procedure to diagnose gradle build failure.
2020-05-07 08:40:28 +02:00
Grigorii Kirgizov
6b82633450
Upd coderules buildscript, regen build.xml
2020-05-07 02:37:35 +03:00
Grigorii Kirgizov
cd3e56c16a
Handle case of language cycles in AspectClique, add simple test with lang cycle (MPSCR-60)
2020-05-07 02:21:26 +03:00
Grigorii Kirgizov
e7d23f9b6d
Redefine how Aspect Cliques are found (fixes MPSCR-60)
...
Now algorithm for finding aspect cliques includes 3 stages:
1) topological sort (as before)
2) bottom-up pass with initial assignment of clique ids (as before)
3) top-down pass (i.e. in reverse topo sort order) (added stage)
The 3rd stage handles case when hierarchy of langs with
required aspect include branching point (with no join further down),
as in the case of closuresExt & collectionsExt both extending blExt,
but unrelated to each other (neither extends the other).
2020-05-07 01:28:14 +03:00
Grigorii Kirgizov
bb5412230a
Fix topo sort in Aspect Clique and add check for graph acyclicity (MPSCR-60)
2020-05-07 01:28:14 +03:00
Grigorii Kirgizov
e1af32b97c
Add tests for closuresExt concerned with yield and sequence, reproduces MPSCR-60
2020-05-07 01:28:14 +03:00
Grigorii Kirgizov
e6b1fe12a7
Don't generate main closureLiteral rule when there's error with return vs. yield
2020-05-07 01:28:14 +03:00
Fedor Isakov
76991aabe7
Fix dependencies among rule tables.
...
Observing the invariant: whenever a constraint is used in
rule's head, the rule table containing it must extend the
one that constraint.
Also drop unused constraint from the head in ConversionFunctionIFace.
2020-05-05 16:23:13 +02:00
Fedor Isakov
2c363f85f4
Tidy up helper methods contract, drop unnecessary method.
...
BaseHelper.getListContents() accepts a dataform that must be
an instance of ListNode or be resolved to one via DataFormUtil.ground().
2020-05-05 15:58:48 +02:00
Fedor Isakov
587711a3e8
Drop deprecated class and its usages.
2020-05-05 15:58:48 +02:00
Fedor Isakov
6904af04ce
Drop instances of deprecated concept.
2020-05-05 15:58:48 +02:00
Fedor Isakov
d3a72049e8
Drop deprecated stuff from coderules lang.
2020-05-05 15:58:48 +02:00
Grigorii Kirgizov
f13b5b3176
Fix a way to get needed clique in incremental tests
2020-05-05 16:45:27 +03:00
Grigorii Kirgizov
54c9af37a3
Add checking of loop statements in blExt
2020-05-05 16:45:27 +03:00
Grigorii Kirgizov
c388aa25b6
Reorganise rule table extends dependencies in blExt
...
Mainly, avoid extending TypeOf by ConversionMain (unnecessary dependency).
It's also more logical structure: tables defining declarations go first, then typeOf-related.
So rule tables which require only decls can depend only on such tables.
Core tables extends relationship now:
TypeBound <- CheckAll <- Generics <- TypeOf
TypeBound <- ConversionMain [<- other langs' conversions]
2020-05-05 16:45:27 +03:00
Fedor Isakov
66d2896fff
Ensure type variable bounds are processed in coerce query.
...
This fixes constraint errors in model check while running
typechecking with coderules.
2020-05-05 13:20:59 +02:00
Fedor Isakov
56c341f615
Fix apparent memory leak in coderules messages view.
...
Use SoftReference wrapping TraceObject to avoid out of memory
error.
2020-05-05 11:42:25 +02:00
Fedor Isakov
a15a6b3f1d
Fix target statement (not allowed within constraint rule).
2020-05-05 10:19:38 +02:00
Fedor Isakov
ab9a22a013
Rebuild project.
2020-05-05 10:19:38 +02:00
Fedor Isakov
2dc2191be3
Editor improvement: auto-substitute name from target concept for rule templates.
2020-05-05 10:19:38 +02:00
Fedor Isakov
2f9c23581f
Fix substitution menu for LogicalItemExpression.
...
Prevent LogicalItemExpression from wrapping ExpressionItem.
2020-05-05 10:19:38 +02:00
Fedor Isakov
4666ca5349
Deprecate an obsolete concept.
2020-05-05 10:19:38 +02:00
Fedor Isakov
f43b262e7f
Introduce helper behaivour methods to be used from typesystem.
2020-05-05 10:19:38 +02:00
Fedor Isakov
ea687efb21
Types for j.m.logic language.
2020-05-05 10:19:32 +02:00
Grigorii Kirgizov
27b7917a1a
Add conversion of closures to functional classifiers, add tests
2020-05-04 16:38:00 +03:00
Grigorii Kirgizov
f75f87f13f
Fix TypecheckingTestHelper to handle case of error types appearing with a reason
...
Error types can appear in cases similar to those of "no type"
because of addittion of "error()" term to typesystem.
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
c6e20d00c2
Handle case of free vars for ternary operation and primitive subtyping (needed for closures)
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
f6ebd46cb6
Disallow using OriginSpec inside rule bodies (such use case isn't handled)
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
590f3ed6ed
Fix usages of OriginSpec: can't use them inside ConstraintRule bodies. Use convertsToSafe instead
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
aa40ca0e01
Fix function conversion to allow coerceTo queries pass
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
36a85d5c2c
Add bl.collectionsExt dependency on bl.function lang; upd mpscore build script and build.xml
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
f7a9c73199
Refactor out lang dependency on function type analogously to sequence type
...
As closures typesystem depends on collections due to sequence type,
so collections typesystem depends on closures due to function type.
E.g. consider typechecking of SequenceCreator.
2020-05-04 15:16:47 +03:00
Grigorii Kirgizov
898087f427
Fix term table in closuresExt to extend blExt term table and use imported sequence type
2020-05-04 15:15:35 +03:00
Grigorii Kirgizov
72d48d76e3
Add typechecking for recursive closure invoke expression, add tests & fix older ones
2020-05-04 15:15:28 +03:00
Grigorii Kirgizov
3284d2c331
Add typechecking of ClosureLiteral and invoke expressions
2020-05-02 14:04:34 +03:00
Grigorii Kirgizov
19ab82586f
Add function type subtyping
2020-05-02 14:04:34 +03:00
Grigorii Kirgizov
b9fe7439bb
Add empty closuresExt files for lang and test solution, upd bulid script
2020-05-02 14:04:34 +03:00
Grigorii Kirgizov
3101d22a5b
Upd mpscore build script and build.xml
2020-05-02 13:44:19 +03:00
Grigorii Kirgizov
735276d2a2
Add import/export constructs for sequence type in collectionsExt to enable basic tests
2020-05-02 13:43:03 +03:00
Grigorii Kirgizov
8921c44a8e
Add first tests for sequence type conversions
2020-05-02 13:43:03 +03:00
Grigorii Kirgizov
451b892b9f
Add empty models for collectionsExt lang and tests
2020-05-02 13:43:03 +03:00
Grigorii Kirgizov
625ea8c049
Add j.m.bl.sequenceBase language with basic sequence typing rules
...
This lang doesn't depend on collections lang and extracts
common dependencies of closures and collections langs:
sequence term and its basic typing rules.
2020-05-02 13:43:03 +03:00
Grigorii Kirgizov
69457dc747
minor fix: extend term tabl from blExt in tuplesExt
2020-05-02 13:43:03 +03:00