@Stargateur I don't know it's current state but when i was developing mobile apps with QT, i remember it was 5.5 or previous , there was a lot of internal bugs, QML wasn't that bad though. I wonder how it works now.

Hey guys! Is there any hope integer division for negative numbers will get fixed? I really hate that it is truncating like C. This behavior is simply not useful! Why did they not adopt flooring like Python did?

@Shepmaster ah I mean if you define a periodic function such that it trivially repeats some mapping like f(x) = sqrt(x) for x ∈ [0,1), f(x) = f(x-1) for x >= 1, f(x) = f(x+1) for x < 0. Then you have some continuous x ∈ ℝ so I would just like to do f(x % 1) to get the correct result - this won't work. I have to do f(x % 1) if x >= 0 else f(x % 1 + 1)

@purefanatic As I said I don't remember the last time I ever had to use an integer division on signed numbers, but in my work (robotics) I'd expect (±n)/(±m) to all give the same absolute value or you'd have symmetricity issues (although anything involving that kind of division would probably be done on floats anyway)

@FrenchBoiethios And yet we check for overflow by default, surely division could have been fixed if it was a real problem

@FrenchBoiethios That does not make any sense. Today, with two's complement, flooring integer division would even be simpler to implement in hardware! The fact that Rust still chooses to work like IDIV in Intel will just reinforce this bad design decision in newer hardware.

@trentcl I read that somewhere but am not certain either. I would guess that unsigned division is simpler and that you can more trivially translate between unsigned division and signed division when using modular arithmetic because two's complement is also modular, but maybe this is insignificant.

@FrenchBoiethios I would like to have the remainder (or rather modulo) like python's %. abs(a%b) does not really make any sense to me. Also, div_euclid and rem_euclid that you linked earlier behave differently to python for negative divisors. But while I stumble over negative dividends from time to time, negative divisors are rare so I could mostly use those functions from i32 and would be happy.

It seems likely that one path is using a Unix socket and the other is using a TCP socket, but you haven't configured your Postgres server to allow TCP connections from that user. — Shepmaster11 mins ago

I have some struct MyStruct that implements trait MyTrait.
How I can map Result<Box<MyStruct>> to get Result<Box<dyn MyTrait>> without passing to map() explicit lambda with the return type?
The code
let res: Result<MyStruct> = Ok(MyStruct{});
let res: Result<Box<dyn MyTrait>> = res.map(B...

I am suffering from Arc<Mutex<_>>, because results of futures change the state of the program and tired of moving Arc Mutexes into the closures, before moving you need to clone them, if you have more than one reference like this it makes code unreadable, you need to give nonsense names to the owners

and also i am always trying to avoid Boxing things but tokio-executor just boxes the whole future before spawn

I have limited futures as spawned, they all do the same work with different inputs, and at the end of each execution they need to create future from other inputs in the queue then spawn. in the end they may fail or get succeed.

system has a strategy according to fail, may retry that input or cancel the whole process

This is a bit abstract and not small example i guess

Also according system's state, whole process may get succeed or continue selecting new inputs from the queue

And this does multipart upload/download with balancing concurrent transfers, since rusoto_s3 fails and exhaust on sloppy networks a lot.

https://play.rust-lang.org/ So ALL i am trying to do is pass arguments from one fn to another. I only wanted to pass the arguments from the fn edit() to fn profile() but realized that i was calling fn profile() everywhere because I am using it as a navigation. My issue is trying to resolve this but when I actully just decide to pass the argumnet to all fns, then i got an error of fn main(first_name: String) { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ incorrect number of function parameters

A finite state machine (FSM) can be directly modeled using two enums, one representing all the states and another representing all the transitions:
#[derive(Debug)]
enum Event {
Coin,
Push,
}
#[derive(Debug)]
enum Turnstyle {
Locked,
Unlocked,
}
impl Turnstyle {
fn next(sel...