« first day (1556 days earlier)      last day (1932 days later) » 

9:42 AM
The compiler literally tells you what's wrong: temporary value is freed at the end of this statement, creates a temporary which is freed while still in use and borrow later used here. I think the error message is pretty clear. If not, please tell us, what you are you understanding. — hellow 3 hours ago
@hellow be careful @E_net4 will be angry
BTW, I'm sure we have a exact duplicate for this
 
9:56 AM
Not only one but a f*ckton I'm sure
 
That is fine. What's not fine is seeing two answers to a question that is most likely a dupe.
 
10:13 AM
>
That works, thanks for the quick response! – fx23 1 hour ago
...
how do you people copy the comment with the links and everything? :/
 
10:40 AM
Am I wrong or is that not possible atm? stackoverflow.com/questions/54233898/…
I guess GATs would help here? ^^
 
10:56 AM
@hellow copy the link of the date
 
11:50 AM
@hellow Not that I know of. The OP wants a trait object using a trait type without specifying all associated types, so I think this is still illegal with GATs.
 
@E_net4wisheshappyholidays Yes it would be
He can't use a trait obj, it would have to be a type parameter
 
I thought something like a enum with two variants? Not sure if that is possible though, because of the different return types
I guess one have to introduce another trait trait GimmeLen { fn len(&self) } which then you implement for that enum?!
But I guess that's a overkill
 
12:18 PM
@hellow Not necessary. Building a more relaxed trait with object safety isn't that bad.
 
12:54 PM
I need to learn how to read ICE stack traces... :/
 
@hellow why?
 
Because I'd like to learn it ^^ currently I try to figure out which commit is responsible for github.com/rust-lang/rust/issues/57673
but if I read the stacktrace correctly ena::unify::UnificationTable<S>>::get_root_key triggered the panic, but I can't find what/where that should be :/
also, what is the "query stack"
 
 
2 hours later…
@Shepmaster thank you!
 
3:24 PM
Could someone upvote this comment (if you agree with it!) so it doesn't get auto-hidden... stackoverflow.com/questions/54229893/…
 
3:37 PM
stackoverflow.com/a/54231303/155423 has so many small logical errors in the rationale.
 
 
2 hours later…
5:32 PM
Oy, let's see some CVs here.
 
5:57 PM
@Shepmaster (context) I know that you know that the code I posted is valid. Where I’m disagreeing with you is that you complained about the OP’s statement “all Foo instances are related to some lifetime 'a that must be shorter than the lifetime of the string passed as parameter to Foo::new”. I don’t think that statement is wrong.
 
Also FYI I'm on mobile watching my baby, so slow to respond.
 
In the example I posted, we’ve clearly called Bar::<'a>::new with a &'static str where 'a is shorter than 'static.
Now, you will tell me that &'static str has been coerced to &'a str. Which is a fine thing to say. But it doesn’t make the OP’s statement wrong.
 
My point is that the lifetime a is the lifetime of the slice as far as Foo is concerned
 
Again, a fine thing to say, but misleading when presented as an argument that the OP’s statement is wrong.
 
Perhaps we are talking about two sides of the "parameter"
For what it’s worth I’m going to delete those comments for now until we figure out the issue
 
6:03 PM
Thanks, I’ll delete my responses too then.
 
To avoid spreading extra confusion
So inside the new function, the lifetimes of the variables no longer matters.
 
Are you saying the OP should have said “argument” instead of “parameter”?
 
I think you are talking about the variables outside and I’m talking about inside.
I can literally never remember which is which, tbh
 
To be pedantically correct in the worst kind of way, the caller passes arguments and the callee receives parameters.
Anyway, it doesn’t matter which side I’m talking about, the question is whether the OP’s statement is wrong.
 
It’s incomplete at best. It should be equal or shorter to start with.
 
6:08 PM
That would be a reasonable comment.
 
Then the next part reasoning is poor.
“When you the write”
Nothing about that, based on the strict and function defined so far, causes anything
In fact lifetime a has to be longer than words.
Of wait.
 
What?
 
I’m mixing variable names.
Hard to read whole code at once
Maybe it is just adding equal or shorter.
 
Cool, I think we’re good then.
 
That may have been my whole problem: misreading what words was.
 
6:15 PM
Well, good thing this misunderstanding didn't last a lifetime. :P
 
@E_net4wisheshappyholidays Look of disapproval gif
@AndersKaseorg thanks for calling me out! Please feel free to lurk around in here with us.
 
6:30 PM
@Shepmaster Oh, we're doing gifs of that look now? õ_õ
 
6:55 PM
@E_net4wisheshappyholidays easier to do on mobile
 
7:13 PM
😒
 
7:50 PM
posted on January 17, 2019 by The Rust Release Team

The Rust team is happy to announce a new version of Rust, 1.32.0. Rust is a programming language that is empowering everyone to build reliable and efficient software. If you have a previous version of Rust installed via rustup, getting Rust 1.32.0 is as easy as: $ rustup update stable If you don't have it already, you can get rustup from the appropriate page on our website, and check out the

5
 
 
1 hour later…
8:54 PM
@Feeds rustup update rustup update rustup update!!!
 
 
1 hour later…
9:57 PM
Is it possible to generate an error in a proc macro at a precise span?
(in stable Rust)
 
10:11 PM
Ok, nevermind… I'm using parse_quote, that's why. It transforms everything into a string, and then it parses it. That loses the spans.
Even parse_macro_input destroys the span information, it seems :'(
 

« first day (1556 days earlier)      last day (1932 days later) »