Skip to content

Fixing some typos and removing references to "checked mode" - #1191

Merged
Sfshaza merged 3 commits into
masterfrom
checked
Aug 29, 2018
Merged

Sfshaza merged 3 commits into
masterfrom
checked

Conversation

@Sfshaza

@Sfshaza Sfshaza commented Aug 27, 2018

Copy link
Copy Markdown
Contributor

Please review, @Hixie.

Comment thread src/debugging.md Outdated
[`setState()`](https://docs.flutter.io/flutter/widgets/State/setState.html)
and thus marking itself dirty. That is why if you look at the dump you
will see that specific object marked "dirty". You can also see what
see that specific object marked "dirty". You can also see what

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is a conditional (has "if you"), shouldn't it be "would" instead of "will"?

As in "That is why, if you looked at the dump, you would see that..."

Or, if you don't want the conditional, it should be "This is why, when you look at the dump, you see that..."

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suppose it's grammatically correct either way. I think I like the last one best, without the "if".

Comment thread src/flutter-for-ios.md Outdated
RegExp regExp = RegExp(p);
RegExp regExp = RegExp(emailRegexp);

return regExp.hasMatch(em);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good coding practice would have this em renamed to something like emailString. em isn't very descriptive...

Comment thread src/debugging.md Outdated
mode. This is the default if you use `flutter run` or the bug icon
in Android Studio. Some tools support assert statements through the
command-line flag `--enable-asserts`. In this mode,
Dart `assert` statements are enabled, and the Flutter framework performs

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a danger that this could be misunderstood: 'performs runtime checks verifying that invariants are not being violated' sounds like we are checking language invariants (like heap soundness: "A variable of type T will never refer to an instance that cannot be typed as a T (but it can be an instance of a subtype)"), but language invariants are always maintained in Dart 2, not just when we run a program with --enable-asserts.

(OK, nobody talks about "trust-something" execution, and I'm pretty sure that we shouldn't mention it here, so we don't. ;-)

The only thing controlled by the --enable-asserts option is whether user-written assert statements are (1) ignored or (2) the argument is evaluated, and if false an AssertionError is thrown.

I don't know how to get the style right here, but maybe we could have something like 'In this mode, Dart assert statements are enabled, and the Flutter framework will then evaluate the argument to each assert statement encountered during execution, and throw if the result is false. This allows developers to enable or disable invariant checking, such that the associated performance cost is only paid during debugging sessions.'

@Sfshaza

Sfshaza commented Aug 29, 2018

Copy link
Copy Markdown
Contributor Author

@eernstg, @gspencergoog, please check the updated version. thx

@Sfshaza

Sfshaza commented Aug 29, 2018

Copy link
Copy Markdown
Contributor Author

I'm still adjusting to Cirrus. @chalin, can you explain why the tests are failing?

@chalin

chalin commented Aug 29, 2018

Copy link
Copy Markdown
Contributor

I'm still adjusting to Cirrus. @chalin, can you explain why the tests are failing?

It is an issue with the container image I believe. We'll need to get that resolved (separately) first.

@chalin

chalin commented Aug 29, 2018

Copy link
Copy Markdown
Contributor

As I've mentioned elsewhere, I've reinstated Travis builds for now. Rebase/merge to pickup the changes.

@Sfshaza

Sfshaza commented Aug 29, 2018

Copy link
Copy Markdown
Contributor Author

No response = tacit approval. ;)

Merging. Please open a new issue if you have other feedback.

@Sfshaza
Sfshaza merged commit 331b94c into master Aug 29, 2018
@Sfshaza
Sfshaza deleted the checked branch August 29, 2018 19:53
@eernstg

eernstg commented Aug 29, 2018

Copy link
Copy Markdown

Sorry, didn't see the request for comments—approval now untacified! ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes Contributor has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants