daml/compiler/damlc/pkg-db
dylant-da 89e2f4db9b
Add warnings to conversion, Warn for tuples size > 5 (#15018)
* Add warnings to conversion

* Fix warning code, add warning for tuples larger than 5 in convertType

* Add flag AllowLargeTuples to ignore when tuples of size > 5 are used

* Predicate tuple warning on AllowLargeTuples flag

* Compile stdlib / prim packages with --allow-large-tuples

* satisfy changelog

CHANGELOG_BEGIN
CHANGELOG_END

* Fix type error in LFConversion test due to runConvertM signature change

* Move warning to convertDataCon, so un-type-annotated uses are detected

* Add TODO

* Add codeGenAllowLargeTuples internal function to DA.Internal.Desugar

* Unsplit convertDataCon and convertDataCon' via envAllowLargeTuples check

* Desugar codeGenAllowLargeTuples call to allow large tuples on subexprs

* Point to GHC with auto-inserted codeGenAllowLargeTuples calls

* Reorder codeGenAllowLargeTuples replacement to be before internals check

* Export codeGenAllowLargeTuples from DA.Internal.Desugar

* Reverse warnings at end of ConvertM run

* Comment role of Either and tuple in ConvertM

* Rename --allow-large-tuples=yes to --disable-warn-large-tuples=yes

* Make disable_warn_large_tuples an option, false by default

* Add tests for tuple size warning

* Use minimum tuple size to trigger large tuple warning

* Disable large tuple warning during stdlib compilation

* Use a pattern synonym for tuple detection

* lint
2022-09-21 14:16:39 +01:00
..
BUILD.bazel Add warnings to conversion, Warn for tuples size > 5 (#15018) 2022-09-21 14:16:39 +01:00
util.bzl Add warnings to conversion, Warn for tuples size > 5 (#15018) 2022-09-21 14:16:39 +01:00