Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disappearing function types in constructor arguments #29225

Closed
mkustermann opened this issue Apr 3, 2017 · 8 comments
Closed

Disappearing function types in constructor arguments #29225

mkustermann opened this issue Apr 3, 2017 · 8 comments
Assignees
Labels
area-front-end Use area-front-end for front end / CFE / kernel format related issues. front-end-fasta front-end-kernel

Comments

@mkustermann
Copy link
Member

From the test in tests/language/function_subtype_inline2_test.dart:

class C {
  var field;
  C.c1(int this.field());
  C.c2({int this.field()});
  C.c3({int field(): null});
  C.c4({int this.field(): null});
  C.c5([int this.field()]);
  C.c6([int field() = null]);
  C.c7([int this.field() = null]);
}
  class C extends core::Object {
    field dynamic field;
    constructor c1(dynamic field) → void
      : test::C::field = field, super core::Object::•()
      ;
    constructor c2({dynamic field = null}) → void
      : test::C::field = field, super core::Object::•()
      ;
    constructor c3({dynamic field = null}) → void
      : test::C::field = null, super core::Object::•()
      ;
    constructor c4({dynamic field = null}) → void
      : test::C::field = field, super core::Object::•()
      ;
    constructor c5([dynamic field = null]) → void
      : test::C::field = field, super core::Object::•()
      ;
    constructor c6([dynamic field = null]) → void
      : test::C::field = null, super core::Object::•()
      ;
    constructor c7([dynamic field = null]) → void
      : test::C::field = field, super core::Object::•()
      ;
  }

Everything becomes dynamic.

This is one of the issues that appears in checked-mode.

@mkustermann
Copy link
Member Author

I think @peter-ahe-google or @stereotype441 fixed this not too long ago.

@peter-ahe-google
Copy link
Contributor

This test is still marked as failing in checked mode.

@mkustermann
Copy link
Member Author

@peter-ahe-google I think that's because the buildbot running the checked mode tests is on FYI and nobody updated the status files, see build where it is passing:

FAILED: dartk-vm-checked release_x64 language/function_subtype_inline2_test
Expected: RuntimeError 
Actual: Pass
CommandOutput[vm]:

Command[vm]: DART_CONFIGURATION=ReleaseX64 out/ReleaseX64/dart --dfe=out/ReleaseX64/gen/kernel-service.dart.snapshot --kernel-binaries=out/ReleaseX64/patched_sdk --enable_asserts --enable_type_checks --ignore-unrecognized-flags --packages=/b/build/slave/vm-kernel-linux-release-x64-checked-be/build/sdk/.packages /b/build/slave/vm-kernel-linux-release-x64-checked-be/build/sdk/tests/language/function_subtype_inline2_test.dart
Took 0:00:01.351702

Short reproduction command (experimental):
    python tools/test.py -m release -c dartk --checked --builder-tag no_ipv6 language/function_subtype_inline2_test

Since I'm the gardener today, I'll update status files for it and start moving it to the main waterfall. It has the same cycle time as the other builders we have there (and since kernel integration is now getting integrated into flutter, which e.g. uses checked mode, we really need to ensure we test it (and act upon new failures )).

@peter-ahe-google
Copy link
Contributor

Please don't move them to the main waterfall yet. I can't keep them green without doubling my testing time.

@mkustermann
Copy link
Member Author

I don't think our engineers are expected to run every single possible configuration for every CL before submitting. People should test what they think gives good coverage and let the buildbot do the exhaustive test matrix. It's not an ideal setup, but @whesse is working on getting us try bots atm.

If we have something our customers are using, we have to know when we break it. Currently we don't get notified on any breakages for checked mode issues (as well as precompilation issues).

People are pushing hard to get kernel support in the VM ready so flutter can also use it, so we really have to test it (whatever infrastructure we have available now).

At least I'll update the status files for checked mode, and maybe prepare a CL we can land if there is agreement on the builder.

@peter-ahe-google
Copy link
Contributor

Please discuss this with @mraleph.

If I don't test all combinations and break something, my changes are likely to be reverted.

In my opinion, it would be better to turn off checked mode until we have less bugs in production mode.

@whesse
Copy link
Contributor

whesse commented Jun 22, 2017

There will be always be a tradeoff between trybot coverage (or local testing) completeness and resources used, so it is inevitable that some changes will get reverted when the full buildbot shows unexpected failures. If is easier to fix breakages in checked mode as they occur, rather than letting them build up, I think it is worth having more reverts happen. But just adding one checked configuration should catch most errors, and shouldn't double the testing matrix.

@peter-ahe-google
Copy link
Contributor

Yes. It is a tradeoff. This is why @mraleph needs to be involved.

@sigmundch sigmundch added the area-front-end Use area-front-end for front end / CFE / kernel format related issues. label Oct 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-front-end Use area-front-end for front end / CFE / kernel format related issues. front-end-fasta front-end-kernel
Projects
None yet
Development

No branches or pull requests

5 participants