Grigorii Kirgizov
b07fdd6735
Reproduce MPSCR-55
2020-04-19 13:43:01 +03:00
Grigorii Kirgizov
4bb1b9d3d8
Apply some migrations after rebase on master
2020-04-19 13:42:53 +03:00
Fedor Isakov
9f7d60e7c1
Reorder macro template declarations: move abstract concept to the bottom.
2020-04-16 12:25:59 +02:00
Fedor Isakov
7cc19bdece
Minor code fix: remove unnecessary wrapping of logical var.
2020-04-15 11:14:38 +02:00
Fedor Isakov
eb4862eb48
Force save all models -- update resolve info.
2020-04-14 16:20:05 +02:00
Fedor Isakov
fcbdbe7e47
Attempt to fix gradle task deps graph.
2020-04-13 18:00:15 +02:00
Fedor Isakov
35fd816cbc
Update all usages of moved concepts.
2020-04-13 18:00:15 +02:00
Fedor Isakov
fd2043e047
Update build scripts.
2020-04-13 18:00:15 +02:00
Fedor Isakov
1336e82065
Fix wrongly used logical item expression.
2020-04-13 17:58:34 +02:00
Fedor Isakov
5b1449fa82
Update all usages of moved concepts.
2020-04-13 17:58:34 +02:00
Fedor Isakov
296b3e9271
Re-apply all rerunnable migrations.
2020-04-13 17:58:33 +02:00
Fedor Isakov
a1c98b5bf0
Apply all outstanding migrations.
2020-04-13 17:58:33 +02:00
Fedor Isakov
52bca36d32
Rebuild project.
2020-04-13 17:58:33 +02:00
Fedor Isakov
7413e9e387
Force save all models.
2020-04-13 17:58:33 +02:00
Fedor Isakov
cac5573cb9
Drop instances of deprecated concepts in baseLangExt
...
.
2020-04-13 17:58:33 +02:00
Fedor Isakov
d22abb3835
Drop instances of deprecated concepts in lambdacalc.
2020-04-13 17:58:33 +02:00
Grigorii Kirgizov
145aa79753
Regenerate build.xml for mpscore
2020-04-13 15:10:37 +03:00
Grigorii Kirgizov
bd87873160
Move baseLanguage.tuplesExt lang to 'samples' and upd build script
2020-04-13 14:36:37 +03:00
Grigorii Kirgizov
8dfcff1844
Add typechecking for indexed tuples (new language .tuplesExt and tests)
2020-04-08 23:24:55 +03:00
Fedor Isakov
4e12f7bf3b
Migrate baseLanguageExt sample to new expand/call macros.
2020-03-31 18:44:07 +02:00
Fedor Isakov
6a431fcb49
Rebuild project.
2020-03-31 18:44:07 +02:00
Fedor Isakov
ffcc74459f
Migrate fitch samples to new expand/call macros.
2020-03-31 11:43:30 +02:00
Fedor Isakov
538632a8a3
Migrate lambdacalc sample to new expand/call macros.
2020-03-31 11:43:30 +02:00
Grigorii Kirgizov
79952036cd
Fix ternary operator typechecking
2020-03-26 18:17:06 +03:00
Grigorii Kirgizov
6a53d15a21
Refactor: move logic related to tracking parent match from ControllerImpl to MatchJournal
...
Relates to machinery introduced in MPSCR-47.
Previously parent match was maintained in Controller on Java call stack.
Now this stack of parent matches is maintained manually in MatchJournal.
So MatchJournal gains new invariant: parentChunk()
returns correct parent after each logMatch() call.
Several tests fail, also need to maintain this
invariant after logActivation() calls.
2020-03-26 13:40:41 +03:00
Grigorii Kirgizov
c51d767926
Add typechecking for all missing operators. Refine missing cases, check compatibility. Properly handle ternary op. Add tests. (MPSCR-3)
2020-03-25 20:11:52 +03:00
Grigorii Kirgizov
b6aaec8870
Revert temporary workaround for MPSCR-51 from 16e39a93
2020-03-23 14:39:54 +03:00
Grigorii Kirgizov
91e4d2b582
Revive 'principal' rule feature for MPSCR-51. Mark those rules in BL typesystem.
...
Introduce 'auxiliary/essential' notions instead of 'principal/not principal'.
2020-03-23 14:28:14 +03:00
Grigorii Kirgizov
8874e8eb2c
Complete checking rules for overriding methods (add signature clash check, JLS12 8.4.8). Add tests for that. (MPSCR-3)
2020-03-18 19:50:17 +03:00
Grigorii Kirgizov
7a5a5388b1
minor fix: suppress out of scope error in node test code
2020-03-17 18:36:41 +03:00
Grigorii Kirgizov
16e39a9345
Check applicable scope for certain checking rules in BL (workaround for BL for MPSCR-51). Fix SubclassingUtil.
...
Modified TYPECHECK query to include "checkingScope" query parameter:
it is a root node for which program is generated (for local typechecking it's local node).
Rules additionally match on a constraint `checkDecls(node<>)` bearing this node,
so while rules will be generated for all scopes, only those in applicable scopes will run.
Also split rule for EnumConstantDeclaration on declration checking and just typing rule.
2020-03-17 17:54:38 +03:00
Grigorii Kirgizov
8d1f086562
Rewrite check_ClassifierOverridingMethods checking rule in Coderules. Rename several rules. (MPSCR-3)
2020-03-17 13:14:41 +03:00
Grigorii Kirgizov
455aea18d0
Refactor: compute instantiated subclass paths in SubclassingUtil more efficiently and allow resolving type vars with it
2020-03-16 17:59:19 +03:00
Grigorii Kirgizov
873d04c907
Add typechecking of Enums (MPSCR-3). Also avoid getting Classifier types with prim types as type args
...
Now primitive types in conversion relation are handled before processing of free inference vars.
So primitive types first get boxed and only then these terms can be unified with inference vars.
2020-03-16 16:42:03 +03:00
Grigorii Kirgizov
7c40295948
Add test cases for boxing/unboxing, complete typechecking for boxing (MPSCR-3)
2020-03-12 18:02:21 +03:00
Grigorii Kirgizov
a5cc88aeef
Fix typechecking for qualified this expr (MPSCR-3)
2020-03-12 14:54:40 +03:00
Grigorii Kirgizov
73fd59e58e
Add more test code for checking some cases of BL method overriding logic. Muted for now. (MPSCR-3)
...
It's unclear who should handle this: coderules or old typesystem checking rules.
2020-03-12 14:01:30 +03:00
Grigorii Kirgizov
a2d28e566a
Tried to reproduce MPSCR-50 -- typechecking works okey, problem lies elsewhere
2020-03-12 10:36:26 +03:00
Grigorii Kirgizov
a4d561b5a4
Drop now unused subclassing / promote rules operating on raw Classifier values
2020-03-11 15:51:26 +03:00
Grigorii Kirgizov
88a433584b
Simplify subclassPaths rule, add a test for now used SubclassingUtil's method
...
Previously type substitution in subclssing path is computed
by helper method instead of a code inside rule template.
2020-03-11 15:46:16 +03:00
Grigorii Kirgizov
fea3d5d021
minor: align NestedGenerics test with javac
2020-03-11 15:22:54 +03:00
Grigorii Kirgizov
7b143bdb6f
Ensure typeVarBound constraint is produced once for each tv decl. Fix capture of type var.
...
Fixes typechecking tests.
Type var bounds are produced together with genDecls at program start.
Now bound of type var is captured only when needed --
inside convertsTo check, leaving typeVarBound intact.
2020-03-11 12:29:43 +03:00
Fedor Isakov
253a7609a3
Introduce typeVarBound constraint to handle typevar bounds.
...
Since it's no longer possible to have cyclic terms,
the term for type variable type has to be refactored:
the bound information is attached via typeVarBound constraint
on the type.
2020-03-11 12:29:19 +03:00
Fedor Isakov
4020989bde
Defensive copying of argument list.
...
SModel returns a model-based list by default.
Since it is used w/o a read action, we need to copy the list
to be used as constraint's argument.
2020-03-11 12:28:22 +03:00
Grigorii Kirgizov
e1ac188023
Produce proper type erasure for raw classifiers: type variables are erased to their bounds
2020-03-11 09:41:18 +03:00
Grigorii Kirgizov
d3d567101f
Add typechecking for return type covariance and tests for it (MPSCR-3)
2020-03-11 09:41:08 +03:00
Grigorii Kirgizov
92f95674b3
Refactor: drop meaningless DataForm.asRoot (used symbolPath which is deprecated)
2020-03-06 14:04:18 +03:00
Fedor Isakov
f2bb87e1b0
Apply migration to replace deprecated concept.
2020-02-26 15:03:31 +01:00
Fedor Isakov
7ba7c983cb
Apply migration to use logical variable ref expression.
2020-02-24 22:57:05 +01:00
Fedor Isakov
e1c5f68e3e
Typechecking templates: minor refactoring, optimizing code.
...
Replace node-ptr<> type with node<> where applicable.
Use node<> type is ok in constraint arguments.
Replace instances of LateExpressionItem $() with ExpressionItem.
2020-02-20 14:52:28 +01:00