Comments (6)
Building with rust 1.11.0 works. Let me know if I should file an issue with rust.
ubuntu@host:~/syn$ rustc --version --verbose
rustc 1.11.0 (9b21dcd6a 2016-08-15)
binary: rustc
commit-hash: 9b21dcd6a89f38e8ceccb2ede8c9027cb409f6e3
commit-date: 2016-08-15
host: x86_64-unknown-linux-gnu
release: 1.11.0
ubuntu@host:~/syn$ cargo build --release --verbose
Updating registry `https://github.com/rust-lang/crates.io-index`
Compiling quote v0.2.0
Running `rustc /home/ubuntu/.cargo/registry/src/github.com-1ecc6299db9ec823/quote-0.2.0/src/lib.rs --crate-name quote --crate-type lib -C opt-level=3 -C metadata=9442466506b24325 -C extra-filename=-9442466506b24325 --out-dir /home/ubuntu/syn/target/release/deps --emit=dep-info,link -L dependency=/home/ubuntu/syn/target/release/deps -L dependency=/home/ubuntu/syn/target/release/deps --cap-lints allow`
Compiling syn v0.8.0 (file:///home/ubuntu/syn)
Running `rustc src/lib.rs --crate-name syn --crate-type lib -C opt-level=3 --cfg feature=\"quote\" --cfg feature=\"default\" --cfg feature=\"printing\" --cfg feature=\"parsing\" --out-dir /home/ubuntu/syn/target/release --emit=dep-info,link -L dependency=/home/ubuntu/syn/target/release -L dependency=/home/ubuntu/syn/target/release/deps --extern quote=/home/ubuntu/syn/target/release/deps/libquote-9442466506b24325.rlib`
from syn.
Definitely a compiler bug.
It goes away with this commit 3a2ea4b so I have a lead.
from syn.
@dtolnay Thanks. I filed an issue before I read your response. It is here: rust-lang/rust#36875
from syn.
Narrowed down further: e8b4e20.
from syn.
I can't work on this right now but I will do my best to release a workaround later tonight.
from syn.
I released a workaround in 0.8.1.
The following code triggered the bug:
pub fn str_chars(s: &str) -> Vec<char> {
s.chars().collect()
}
The following workaround avoided the bug:
pub fn str_chars(s: &str) -> Vec<char> {
let mut result = Vec::new();
for ch in s.chars() {
result.push(ch);
}
result
}
from syn.
Related Issues (20)
- Delete From impls of ast enums HOT 2
- Consider inserting invisible groups, rather than parens, when applying grouping for precedence HOT 1
- Implement `Debug` for the AST nodes HOT 1
- parse_nested_meta don't work on attribute with multiple meta HOT 2
- Struct Literals in ExprLet HOT 1
- Parse `safe` items in extern blocks
- Parse precise capturing syntax HOT 1
- Scope when parsing delimited group content does not necessarily belong to the right Group token
- Parsing function using `parse` referencing enum fails HOT 1
- Parse attributes on where-predicates
- Deny keyword lifetimes pre-expansion
- Parse unsafe attributes
- Parse unnamed C varargs within function pointer types HOT 1
- [Feature Request] Add support for incomplete expression and statement HOT 1
- FieldMutability is missing Parse and ToTokens HOT 1
- Breaking change to `Generics::lifetimes` in v2.0.73 HOT 8
- ExprPath to_tokens() output can't be parsed as an expression due to missing turbofish
- A
- Documentation discrepancy between `parse` and `parse2`
- Generics::split_for_impl can cause clippy::multiple_bound_locations HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from syn.