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

Documentation : Tutorial improvement. #12472

Closed
wants to merge 1 commit into from
Closed

Documentation : Tutorial improvement. #12472

wants to merge 1 commit into from

Conversation

darnuria
Copy link
Contributor

Refactoring examples on implementation of generics for linked list.
Fixing typo of 'Note's for coherency.

Adding internal links inside the tutorial example with traits,
generics etc...

1349 // The followings examples directly calls the impl of Eq for list.

I am not really confident with "directly calls the impl of Eq for list." the
idea is to explain that you can compare with self.eq method and '==' operator
thanks to Eq impl.

Adding a note in 2.1 section.

(update after git rebase)

@darnuria
Copy link
Contributor Author

@pnkfelix : I began to work on the modifications to the tutorial we talked about yesterday at Mozspace.

@@ -134,6 +134,9 @@ fn main() {
}
~~~~

> ***Note:*** `Macro` or `syntax extensions` are explained in section :
Copy link
Contributor

Choose a reason for hiding this comment

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

Why backticks? This isn't code. Also, MacroMacros.

Side note: in English there is no space before a colon.

I would probably phrase it like this:
> ***Note:*** *Macros* are explained in the [Syntax extensions (3.4)](#syntax-extensions) section.

@adrientetar
Copy link
Contributor

@darnuria How was the meeting? Too bad I couldn't be there.

@darnuria
Copy link
Contributor Author

@adrientetar : This was not the meetup we just meet at the Mozilla space for the monthly party. And now we have a reps page for the meetup : https://reps.mozilla.org/e/meetup-rust-paris-2014/ ;)
I will take care of your advise and revise my pull-request. :)

@darnuria
Copy link
Contributor Author

@pnkfelix , @adrientetar , @huonw : review newest modification? :)
If it's ok I will rebase. :)

assert!(!xs.ne(&ys));

// The Eq trait also provides us with shorthand infix operators.
Copy link
Member

Choose a reason for hiding this comment

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

"The Eq trait also allows us to use the shorthand infix operators"

@huonw
Copy link
Member

huonw commented Feb 24, 2014

(BTW, I'd just like to remind you of this comment, so you don't spend too much effort on the tutorial right now. :) )

@darnuria
Copy link
Contributor Author

I know but actually this one is read by a lot of peoples. So making minor fixes is right no? :S

@huonw
Copy link
Member

huonw commented Feb 24, 2014

Yes, that's good; I'm just pointing out more extensive work may be a waste of time (i.e. larger changes may be deleted later, or modified beyond recognition).

@darnuria
Copy link
Contributor Author

I know. We talked about it with Felix Friday evening.
So lets rebase and review?

(For rebase every time I have the same question)

# This is a good practice? I am not sure.
git rebase -i HEAD^^^ # For this example
# Selecting my commits etc..
git push origin branch_name # And here I dont know if I must add -f... how do you do it?

@pnkfelix
Copy link
Member

@darnuria Remind me to show you my git work-flow at the meetup tomorrow night.

Refactoring examples on implementation of generics for linked list.
Fixing typo of 'Note's for coherancy.

Adding internal links inside the tutorial example with traits,
generics etc...
@liigo
Copy link
Contributor

liigo commented Feb 24, 2014

I like to known too.
2014年2月24日 下午10:40于 "Felix S Klock II" notifications@github.com写道:

@darnuria https://github.com/darnuria Remind me to show you my git
work-flow at the meetup tomorrow night.


Reply to this email directly or view it on GitHubhttps://github.com//pull/12472#issuecomment-35891981
.

@pnkfelix
Copy link
Member

@darnuria ... and I forgot to talk to you about this last night. :)

Well, I did not really have too much to say, beyond this: My strategy with git tends to be, use git checkout -b <new_branch_name> frequently, to put names on current locations in the commit graph. In particular, I try never to make any edits to code while on mozilla's master branch; for any edit that I am about to make, I first checkout a fresh branch. Then after I've made a series of commits on that branch, I do git rebase -i master to review/reorder/squash/edit my commits. This way I don't have to use HEAD-relative addressing the way that you did in your example of git rebase -i HEAD^^^. (I do use HEAD-relative addressing at times, but only for quick local hacks.)

As for your other question, you should usually not need to use the -f flag to git push. So I try not to use it unless I have to. The main case where one does need to use -f is when you had already published your branch, and then you later rebase it, thus revising the already-published commit history associated with that branch name.

@adrientetar
Copy link
Contributor

@darnuria @pnkfelix The Mozilla Reps page says Tuesday and Wednesday, is that accurate?
I was in front of the Mozilla office a bit past 21h and there was no one upstairs. Or maybe I was just too late. No worries anyway, it was on my way.

@pnkfelix
Copy link
Member

@adrientetar I'm not sure what page you are looking at. I don't want to further derail this ticket, so you should probably send @darnuria and/or myself an e-mail.

@darnuria
Copy link
Contributor Author

@pnkfelix Thanks for the tips thats already what I do. But I am happy to find confirmation I am used to avoid -f too. :)

And for this Pull request? r?

@pnkfelix
Copy link
Member

@darnuria FYI the only "requirement" is the revision to the Note below println!("hello?");. The other notes are just suggestions. I will r+ even if you only incorporate feedback the about println!.

@pnkfelix
Copy link
Member

I talked to @darnuria . He did not mind me making my suggested edits locally on my own PR.

closing this in favor of PR #12599, which I will be r+'ing shortly.

@pnkfelix pnkfelix closed this Feb 27, 2014
alexcrichton pushed a commit to alexcrichton/rust that referenced this pull request Feb 28, 2014
bors added a commit that referenced this pull request Feb 28, 2014
Closes #12546 (Add new target 'make dist-osx' to create a .pkg installer for OS X) r=brson
Closes #12575 (rustc: Move local native libs back in link-args) r=brson
Closes #12587 (Provide a more helpful error for tests that fail due to noexec) r=brson
Closes #12589 (rustc: Remove codemap and reachable from metadata encoder) r=alexcrichton
Closes #12591 (Fix syntax::ext::deriving{,::*} docs formatting.) r=huonw
Closes #12592 (Miscellaneous Vim improvements) r=alexcrichton
Closes #12596 (path: Implement windows::make_non_verbatim()) r=alexcrichton
Closes #12598 (Improve the ctags function regular expression) r=alexcrichton
Closes #12599 (Tutorial improvement (new variant of PR #12472).) r=pnkfelix
Closes #12603 (std: Export the select! macro) r=pcwalton
Closes #12605 (Fix typo in doc of Binary trait in std::fmt) r=alexcrichton
Closes #12613 (Fix bytepos_to_file_charpos) r=brson
@darnuria
Copy link
Contributor Author

darnuria commented Mar 1, 2014

(for History purpose)
@pnkfelix No problem you can do anything which is good to Rust with my PR. ;)
But don't spent too much time on tutorial like brson said : #9874 (comment)

bors added a commit to rust-lang-ci/rust that referenced this pull request Jul 25, 2022
matthiaskrgr pushed a commit to matthiaskrgr/rust that referenced this pull request Mar 21, 2024
Don't emit `doc_markdown` lint for missing backticks if it's inside a quote

Fixes rust-lang#10262.

changelog: Don't emit `doc_markdown` lint for missing backticks if it's inside a quote
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

Successfully merging this pull request may close these issues.

5 participants