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

Frog crashes instead of reporting an error #644

Closed
peter-ahe-google opened this issue Nov 30, 2011 · 3 comments
Closed

Frog crashes instead of reporting an error #644

peter-ahe-google opened this issue Nov 30, 2011 · 3 comments
Milestone

Comments

@peter-ahe-google
Copy link
Contributor

$ cat fisk.dart
class T {
  toString() => "class T";
}

class Foo<T> {
  m() => new T();
}

class Bar extends Foo {
}

main() {
  print(new Bar().m());
}
$ ./frogsh fisk.dart

We are sorry, but... no constructors on type parameters yet

node.js:201
        throw e; // process.nextTick error, or 'error' event on first tick
              ^
CompilerException: We are sorry, but... no constructors on type parameters yet
    at World._message (frogsh:23264:5)
    at World.internalError (frogsh:23287:8)
    at ParameterType.getConstructor (frogsh:21501:18)
    at ParameterType.getConstructor$1 (frogsh:21525:15)
    at MethodGenerator.visitNewExpression (frogsh:14264:16)
    at lang_NewExpression.visit (frogsh:20744:18)
    at MethodGenerator.visitValue (frogsh:13523:20)
    at MethodGenerator.visitTypedValue (frogsh:13528:15)
    at MethodGenerator.visitReturnStatement (frogsh:13601:22)
    at ReturnStatement.visit (frogsh:20362:18)

$ dartc_test fisk.dart
fisk.dart:6: New expression cannot be invoked on type variable
     5: class Foo<T> {
     6: m() => new T();
Compilation failed with 1 problem.

@jmesserly
Copy link

That's not actually a "crash" ... it's an internal error: "no constructors on type parameters yet" :)
Should be a really simple fix, just changing the error level and making sure we have the right span.

@jmesserly
Copy link

Removed this from the FrogEditor milestone.
Added this to the Release1.0 milestone.

@jmesserly
Copy link

Added Fixed label.

@peter-ahe-google peter-ahe-google added this to the Release1.0 milestone Dec 6, 2011
copybara-service bot pushed a commit that referenced this issue Jun 15, 2022
…ions)

https://dart.googlesource.com/protobuf/+log/408f69b98b2d..3105588b8e51

2022-06-15 [email protected] Remove unused function
2022-06-15 [email protected] Simplify PbList implementation, fix freezing (#626)
2022-06-15 [email protected] Remove frozen message modification handling (#643)
2022-06-15 [email protected] Bump version number for development, add changelog entry for #644
2022-06-15 [email protected] Remove ReadonlyMessageMixin (#644)
2022-06-15 [email protected] Release protobuf-2.1.0, protoc_plugin-20.0.1 (#677)
2022-06-14 [email protected] Specify `GeneratedMessage operator==` argument type (#675)
2022-06-14 [email protected] Add changes since the last protobuf release to CHANGELOG (#619)
2022-06-10 [email protected] Tweak consts.dart docs (#674)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dart-protobuf-dart-sdk
Please CC [email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Dart Protobuf Support: https://github.com/dart-lang/protobuf/issues
To file a bug in Dart SDK: https://github.com/dart-lang/sdk/issues

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Tbr: [email protected]
Change-Id: If0f2beb1f63ef9a7527abaa116d883ef0fd4b6c9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/248620
Commit-Queue: Nate Bosch <[email protected]>
Reviewed-by: Nate Bosch <[email protected]>
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants