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

assert statements look like functions #936

Closed
DartBot opened this issue Dec 22, 2011 · 7 comments
Closed

assert statements look like functions #936

DartBot opened this issue Dec 22, 2011 · 7 comments
Assignees
Labels
area-language Dart language related items (some items might be better tracked at github.com/dart-lang/language). closed-not-planned Closed as we don't intend to take action on the reported issue type-enhancement A request for a change that isn't a bug

Comments

@DartBot
Copy link

DartBot commented Dec 22, 2011

This issue was originally filed by jjinux...@google.com


I read the language spec, and I have a comment to make on assert statements:

I see no reason to use ()'s with assert statements. With if statements, you
need the parenthesis to separate the conditional from the body. return
statements don't need ()'s. I don't think ()'s should be necessary with
return statements. Removing the need for ()'s will not break code. On the
other hand, requiring ()'s makes it possible to one day switch to using a
function. However, doing so would be bad to programmers who may be counting
on the cost of assert always being nil in production.

@DartBot
Copy link
Author

DartBot commented Dec 22, 2011

This comment was originally written by drfibonacci@google.com


Added Area-Language, Triaged labels.

@gbracha
Copy link
Contributor

gbracha commented Jan 3, 2012

Set owner to @gbracha.
Added Accepted label.

@gbracha
Copy link
Contributor

gbracha commented Jan 3, 2012

Removed Type-Defect label.
Added Type-Enhancement label.

@anders-sandholm
Copy link
Contributor

Added this to the Later milestone.

@kasperl
Copy link

kasperl commented Jul 10, 2014

Removed this from the Later milestone.
Added Oldschool-Milestone-Later label.

@kasperl
Copy link

kasperl commented Aug 4, 2014

Removed Oldschool-Milestone-Later label.

@gbracha
Copy link
Contributor

gbracha commented Aug 22, 2014

Added WontFix label.

@DartBot DartBot added Type-Enhancement area-language Dart language related items (some items might be better tracked at github.com/dart-lang/language). labels Aug 22, 2014
@kevmoo kevmoo added closed-not-planned Closed as we don't intend to take action on the reported issue type-enhancement A request for a change that isn't a bug and removed resolution-wont_fix labels Mar 1, 2016
dart-bot pushed a commit that referenced this issue Mar 17, 2021
2021-03-17 sgrekhov@unipro.ru Fixes #1017. Use => for setter returning value tests
2021-03-16 irina.arkhipets@gmail.com Issue #996: more tests for Generic functions as type arguments and bounds added.
2021-03-16 sgrekhov@unipro.ru Fixes #1005. Description updated for method_definition tests
2021-03-16 sgrekhov@unipro.ru Fixes #1011. Expect an error if non-function type is called as a function
2021-03-16 irina.arkhipets@gmail.com Issue #996: tests for Generic functions as type arguments and bounds re-factored, more tests added.
2021-03-15 irina.arkhipets@gmail.com Issue #996: tests for Generic functions as type arguments and bounds added.
2021-03-15 irina.arkhipets@gmail.com Issue #996: tests for Generic functions as type arguments and bounds added.
2021-03-15 sgrekhov@unipro.ru Missed experiment flag added
2021-03-12 irina.arkhipets@gmail.com Issue #996: tests for Generic functions as type arguments and bounds added.
2021-03-12 sgrekhov@unipro.ru #993. Added tests checking that Struct fields cannot have initializers
2021-03-12 sgrekhov@unipro.ru #993. Tests for not external members of Struct subtype added
2021-03-11 sgrekhov@unipro.ru #993. Use package ffi in co19 ffi tests
2021-03-09 sgrekhov@unipro.ru Fixes #995. Annotations with type arguments tests added
2021-03-09 irina.arkhipets@gmail.com Issue #997: existing triple-shift tests corrected.
2021-03-09 irina.arkhipets@gmail.com More fixes for #535: split constant evaluation tests because static behavior of the strong and weak mode is different.
2021-03-04 sgrekhov@unipro.ru #993. Array tests added
2021-03-04 sgrekhov@unipro.ru #993. Pointer equality tests added
2021-03-03 sgrekhov@unipro.ru #993. Pointer.elementAt() tests added
2021-03-02 sgrekhov@unipro.ru #993. Pointer.cast() tests added
2021-03-01 sgrekhov@unipro.ru #993. Pointer tests added
2021-03-01 sgrekhov@unipro.ru Fixes #936. Change expected result according to the new left top rule
2021-02-26 irina.arkhipets@gmail.com Fixed #998: tests checks output streams correctly now.
2021-02-26 sgrekhov@unipro.ru #993. IntPtr tests added
2021-02-26 sgrekhov@unipro.ru #993. More Struct tests added
2021-02-25 irina.arkhipets@gmail.com Tests updated, missing issue tags added.
2021-02-25 sgrekhov@unipro.ru #1003. Isolate test fixed to not to be a racy
2021-02-25 sgrekhov@unipro.ru Issue numbers added
2021-02-24 sgrekhov@unipro.ru Issue number added
2021-02-24 sgrekhov@unipro.ru #988. Typo in error message fixed
2021-02-24 sgrekhov@unipro.ru #988. Fix test expectations

Cq-Include-Trybots: dart/try:analyzer-nnbd-linux-release-try,dart2js-nnbd-linux-x64-chrome-try,ddc-nnbd-linux-release-chrome-try,front-end-nnbd-linux-release-x64-try,vm-kernel-nnbd-linux-debug-x64-try,vm-kernel-nnbd-linux-release-simarm64-try,vm-kernel-nnbd-linux-release-x64-try,vm-kernel-nnbd-mac-release-x64-try,vm-kernel-nnbd-win-release-x64-try,vm-kernel-precomp-nnbd-linux-debug-x64-try,vm-kernel-precomp-nnbd-linux-release-simarm64-try,vm-kernel-precomp-nnbd-linux-release-x64-try
Change-Id: I718644028b1d2a9fbba0c7efdf2923bb67184fde
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/191409
Reviewed-by: William Hesse <whesse@google.com>
copybara-service bot pushed a commit that referenced this issue Jun 1, 2023
…native, protobuf, pub_semver, shelf, stack_trace, tools, vector_math, webdev

Revisions updated by `dart tools/rev_sdk_deps.dart`.

args (https://github.com/dart-lang/args/compare/f0f6cd2..a9543c0):
  a9543c0  2023-05-31  Devon Carew  switch to using package:dart_flutter_team_lints (#247)
  36407ea  2023-05-31  Devon Carew  adjust the validation of mandatory options (#246)

bazel_worker (https://github.com/dart-lang/bazel_worker/compare/d9b389f..c14a268):
  c14a268  2023-05-31  Kevin Moore  Bump lints, regenerate proto file, fix script (#74)

dartdoc (https://github.com/dart-lang/dartdoc/compare/950898f..39fe1a8):
  39fe1a8a  2023-05-31  Parker Lougheed  Update highlight.js to 11.8.0 for Dart 3 syntax highlighting (#3416)
  4574e819  2023-05-30  Sam Rawlins  Convert kind to an enum (#3426)

http (https://github.com/dart-lang/http/compare/18a43a2..8834aec):
  8834aec  2023-05-31  Brian Quinlan  Update readme and prepare for a new release (#954)
  aca7f0e  2023-05-31  dependabot[bot]  Bump futureware-tech/simulator-action from 1 to 2 (#936)
  7a238a9  2023-05-31  dependabot[bot]  Bump actions/labeler from 4.0.2 to 4.0.4 (#952)
  4c0eb48  2023-05-30  Brian Quinlan  Prepare to publish cupertino_http 1.0.0 (#951)

leak_tracker (https://github.com/dart-lang/leak_tracker/compare/7f2cab3..cbbdeca):
  cbbdeca  2023-05-31  Polina Cherkasova  Improve getting retaining path. (#69)

mockito (https://github.com/dart-lang/mockito/compare/40fe2ca..924f65c):
  924f65c  2023-06-01  Ilya Yanok  Add support for records

native (https://github.com/dart-lang/native/compare/76bc55e..c851e69):
  c851e69  2023-06-01  dependabot[bot]  Bump nttld/setup-ndk (#57)
  0df0cad  2023-06-01  dependabot[bot]  Bump actions/labeler from 4.0.3 to 4.0.4 (#58)
  c30faa2  2023-05-31  Daco Harkes  [c_compiler] test install_name_tool behavior (#56)
  45ef2e7  2023-05-31  Daco Harkes  [c_compiler] Support setting the install name of dylibs (#55)

protobuf (https://github.com/dart-lang/protobuf/compare/346a72d..da6953c):
  da6953c  2023-05-31  Kevin Moore  Update to latest lints and Dart SDK (#828)

pub_semver (https://github.com/dart-lang/pub_semver/compare/c034352..3930557):
  3930557  2023-05-31  Kevin Moore  Bump lints, require Dart 3.0 (#89)

shelf (https://github.com/dart-lang/shelf/compare/a404b6a..ce379aa):
  ce379aa  2023-06-01  dependabot[bot]  Bump actions/labeler from 4.0.3 to 4.0.4 (#363)

stack_trace (https://github.com/dart-lang/stack_trace/compare/86f7e30..8b2046e):
  8b2046e  2023-05-31  Devon Carew  blast_repo fixes (#134)

tools (https://github.com/dart-lang/tools/compare/d723a55..389925f):
  389925f  2023-06-01  Elias Yishak  Utility function added to check permissions on directory (#95)
  a436fee  2023-05-31  Elias Yishak  Asserts added to check all relevant GA4 limitations (#96)

vector_math (https://github.com/google/vector_math.dart/compare/cd87f57..a3aca09):
  a3aca09  2023-05-31  Lukas Klingsbo  fix: Revert negation change for Vector2 (#296)

webdev (https://github.com/dart-lang/webdev/compare/d442fa8..f565d7f):
  f565d7f1  2023-05-31  Anna Gringauze  Disable flaky test on windows (#2127)
  6eed300e  2023-05-31  Anna Gringauze  Cleanup expression evalaluation tests (#2125)

Change-Id: Ia568db23bbc923f764cdf323e249175b609d57ee
Tested: affected files are regenerated test goldens
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/306903
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Auto-Submit: Devon Carew <devoncarew@google.com>
Commit-Queue: Devon Carew <devoncarew@google.com>
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-language Dart language related items (some items might be better tracked at github.com/dart-lang/language). closed-not-planned Closed as we don't intend to take action on the reported issue type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

5 participants