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

Add more documentation #329

Merged
merged 2 commits into from Jul 25, 2018

Conversation

Projects
None yet
4 participants
@derekdreery

derekdreery commented Nov 22, 2017

I recently submitted a PR to add documentation. This PR adds some more.

Note it won't merge as-is because it relies on PR #199 in servo/string-cache.

@jdm

Good additions!

let local_names = Path::new(&env::var("CARGO_MANIFEST_DIR").unwrap()).join("local_names.txt");
let mut local_names_atom = string_cache_codegen::AtomType::new("LocalName", "local_name!");
for line in BufReader::new(File::open(&local_names).unwrap()).lines() {
let local_name = line.unwrap();
local_names_atom.atom(&local_name);
local_names_atom.atom(&local_name.to_ascii_lowercase());
}
local_names_atom.write_to(&mut generated).unwrap();
local_names_atom
.with_macro_doc("Takes a local name as a string and returns its key in the a string cache.")

This comment has been minimized.

@jdm

jdm Nov 22, 2017

Member

in the a?

This comment has been minimized.

@derekdreery
.atoms(NAMESPACES.iter().map(|&(_prefix, url)| url))
.write_to(&mut generated)
.unwrap();
writeln!(generated, "#[macro_export] macro_rules! ns {{").unwrap();
// T

This comment has been minimized.

@jdm

This comment has been minimized.

@derekdreery
@@ -119,6 +144,7 @@ impl QualName {
}
}
/// Take a reference as an `ExpandedName`, dropping the unresolved prefix.

This comment has been minimized.

@jdm

jdm Nov 22, 2017

Member

It's not clear what "Take a reference" means in this case.

This comment has been minimized.

@derekdreery

derekdreery Nov 23, 2017

I've changed this to "Take a reference of self". Do you think this is clear enough, or would you rather something else?

This comment has been minimized.

@jdm

jdm Nov 23, 2017

Member

I think Return this qualified name as an ExpandedName without the unresolved prefix. is more clear.

This comment has been minimized.

@derekdreery
//! See the [document object model article on wikipedia][dom wiki] for more information.
//!
//! This implementation stores the information associated with each node once, and then hands out
//! refs to children. The nodes themselves are reference-counted to avoid copy - you can create a

This comment has been minimized.

@jdm

jdm Nov 22, 2017

Member

to avoid copying

@derekdreery derekdreery force-pushed the derekdreery:docs branch from 3108248 to 92b8b6d Nov 23, 2017

@derekdreery

This comment has been minimized.

derekdreery commented Dec 6, 2017

This is blocked on a new release of string-cache-codegen and dependency bumps.

@bors-servo

This comment has been minimized.

Contributor

bors-servo commented Dec 7, 2017

☔️ The latest upstream changes (presumably #332) made this pull request unmergeable. Please resolve the merge conflicts.

@Ygg01

This comment has been minimized.

Contributor

Ygg01 commented Dec 12, 2017

@derekdreery Great work, but it seems some upstream changes, kinda broke it.

@derekdreery

This comment has been minimized.

derekdreery commented Dec 12, 2017

@derekdreery derekdreery force-pushed the derekdreery:docs branch from 92b8b6d to 4b19102 Apr 28, 2018

@derekdreery derekdreery referenced this pull request Jul 25, 2018

Closed

New version #209

Richard Dodd added some commits Nov 22, 2017

@derekdreery derekdreery force-pushed the derekdreery:docs branch from 4b19102 to 0db8e21 Jul 25, 2018

@derekdreery

This comment has been minimized.

derekdreery commented Jul 25, 2018

I'm trying to tidy up old pull requests. I've rebased off latest master (as of 2018-07-25). I think this is ready for review again.

@jdm

This comment has been minimized.

Member

jdm commented Jul 25, 2018

@bors-servo

This comment has been minimized.

Contributor

bors-servo commented Jul 25, 2018

📌 Commit 0db8e21 has been approved by jdm

@bors-servo

This comment has been minimized.

Contributor

bors-servo commented Jul 25, 2018

⌛️ Testing commit 0db8e21 with merge 24bd183...

bors-servo added a commit that referenced this pull request Jul 25, 2018

Auto merge of #329 - derekdreery:docs, r=jdm
Add more documentation

I recently submitted a PR to add documentation. This PR adds some more.

Note it won't merge as-is because it relies on PR [#199 in servo/string-cache].

[#199 in servo/string-cache]: servo/string-cache#199
@bors-servo

This comment has been minimized.

Contributor

bors-servo commented Jul 25, 2018

☀️ Test successful - status-travis
Approved by: jdm
Pushing 24bd183 to master...

@bors-servo bors-servo merged commit 0db8e21 into servo:master Jul 25, 2018

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
homu Test successful
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment