Skip to content
This repository was archived by the owner on May 6, 2020. It is now read-only.

Update for latest libsyntax changes - #44

Merged
erickt merged 3 commits into
serde-deprecated:masterfrom
antrik:rustup
May 3, 2016
Merged

erickt merged 3 commits into
serde-deprecated:masterfrom
antrik:rustup

Conversation

@antrik

@antrik antrik commented May 2, 2016

Copy link
Copy Markdown

Syncs with current nightly (2016-04-28), and bumps version accordingly.

@antrik

antrik commented May 2, 2016

Copy link
Copy Markdown
Author

This turned out more involved than I had hoped for -- but it seems to be working now both with stable and nightly.

This supersedes the (non-functional) PRs #42 and #43 .

antrik added 2 commits May 2, 2016 08:18
Update to current Rust Nightly. (2016-04-28)

Note that this is not a straighforward merge commit, but rather contains
all adaptation necessary to make it work with stable Rust and syntex --
not just fixing the immediate merge conflicts.

In addition to the usual churn in syntex-syntax (`try!` etc.), this also
contains a minor change to syntex proper, to adapt it to an interface
change affecting it.
The recent interface changes are not backwards compatible -- so we need
a new semantic version...
@antrik

antrik commented May 2, 2016

Copy link
Copy Markdown
Author

OK, now it actually works ;-)

Comment thread syntex_syntax/src/attr.rs
attrs.iter().fold(InlineAttr::None, |ia,attr| {
match attr.node.value.node {
MetaItemKind::Word(ref n) if *n == "inline" => {
MetaItemKind::Word(ref n) if n == "inline" => {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

just out of curiosity, did this actually break or was it just possible to omit the explicit deref now? Because I changed something in rustc related to comparison of InternedString with &str

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

oh... nevermind, I didn't get how syntex updates work xD this is actual code from rustc

@marcusklaas

Copy link
Copy Markdown

Great work! Did you have to remove all the unstable features by hand? 😨

@antrik

antrik commented May 2, 2016

Copy link
Copy Markdown
Author

@marcusklaas well, many bits already had been handled in previous updates, and thus were merged in automatically -- but there were many conflicts to resolve by hand; and some new places to handle too... So it was still fairly tedious. (Though some quick Vim macros helped a lot with the repetitive stuff :-) )

@nox

nox commented May 3, 2016

Copy link
Copy Markdown

@antrik I'm confused, why is there a merge in the middle of that PR? Could you rebase it?

@erickt

erickt commented May 3, 2016

Copy link
Copy Markdown

Thanks! This is awesome!

@nox: no, this is the right procedure for syntex. Check out https://github.com/serde-rs/syntex/blob/master/CONTRIBUTING.md. The reason for this is it's much simpler to sync with the upstream rust libsyntax if we store it in a side branch. This allows git to properly merge most changes, while preserving the patches we need to make syntex_syntax still work on stable rust.

@erickt
erickt merged commit 060e561 into serde-deprecated:master May 3, 2016
This was referenced May 3, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

5 participants