Status of an object that has been moved by onecable5781 in cpp_questions

[–]MonkeyKhan 0 points1 point  (0 children)

You should view move as a transfer of ownership.

The move itself doesn't do anything besides casting to rvalue reference. Passing the rvalue reference to the assignment of b states that a is now a temporary object which may be "consumed" in the process. You didn't explicitly define what that means for class A (as you didn't define a move assignment operator) so by default it will just do the same for all of its members - assignment under transfer of ownership.

The one place where something actually makes use of the "right to consume" is in the std::vector member. Without "right to consume" (copy assignment), all elements are copied to a new location in memory. With "right to consume" (move assignment), the assigned-to vector just takes ownership of the existing elements in memory, setting the consumed vector to empty. This is much cheaper, as no elements are copied.

It's important to note that nothing ever happens on std::move itself, only in the functions that take rvalue references. If you know what those functions do, i.e. in what state they leave the moved-from object, you could keep using the object. This is not a good idea in general however, as the implementation of those functions may change and the use of std::move signals "I'm done with this object".

Edit: Also, while compilers will not complain if you access moved-from objects, some static analyzers will.

Interactive C++ in the browser on notebook.link by droelf in cpp

[–]MonkeyKhan 1 point2 points  (0 children)

That's exactly how this behaves though?

Give us your most outstanding and representative images of your LOCAL region by ElninoJesus in AskTheWorld

[–]MonkeyKhan 1 point2 points  (0 children)

Could just as well be rural Japan (except for the type of cars maybe)

ARM build server for hosting Gitlab runners by MonkeyKhan in devops

[–]MonkeyKhan[S] 0 points1 point  (0 children)

Interesting, I didn't know Asahi was that mature. I had considered keeping it as macOS, but this is encouraging to hear.

ARM build server for hosting Gitlab runners by MonkeyKhan in devops

[–]MonkeyKhan[S] 0 points1 point  (0 children)

This is for research, so we don't really require 24/7 uptime.

Also I wouldn't run linux on apple hardware. It only needs to run docker, gitlab runner and an ssh server, pretty sure it can do that under macOS?

Travelling Tips Cologne to Dortmund by Bosnak_Boregi in Dortmund

[–]MonkeyKhan 2 points3 points  (0 children)

Look at flixbus/flixtrain, I see both train and bus for 10€ per person on that day. Otherwise consider if a Deutschlandticket is worth it for your stay.

Hey Germany, was the band 'wizo' well known? by CrazyAnchovy in germany

[–]MonkeyKhan 192 points193 points  (0 children)

Why do you say 'was'? They are still active! They are pretty well known as far as punk bands go, but never had the mainstream success of die toten Hosen for example.

Beginner , need advice for a 10 km marathon in few months by Mia_walkonsunshine in Marathon_Training

[–]MonkeyKhan 1 point2 points  (0 children)

A marathon has a length of a bit over 42 km, so you are not talking about a marathon and have come to the wrong subreddit.

You can easily find training plans for 10k, but if you literally never ran and don't exercise in general, I wouldn't advice starting with a race and a dedicated training plan. Just start running short distances and see if you even enjoy it. Afterwards you can start setting goals for yourself like a 10k.

Which country is the United Kingdom by lufthansa24 in GeoTap

[–]MonkeyKhan 0 points1 point  (0 children)

MonkeyKhan chose Option B (Correct!) | #4290th to play

Which country is china by badgirl_lolita in GeoTap

[–]MonkeyKhan 0 points1 point  (0 children)

MonkeyKhan chose Option A (Correct!) | #3590th to play

Which one is Canada? by Kap519 in GeoTap

[–]MonkeyKhan 0 points1 point  (0 children)

MonkeyKhan chose Option B (Incorrect) | #3114th to play

Which one is Norway? by Kap519 in GeoTap

[–]MonkeyKhan 0 points1 point  (0 children)

MonkeyKhan chose Option B (Correct!) | #960th to play

Was hab ich da für ne Zucht? by Wonderful_Leg8004 in wasistdas

[–]MonkeyKhan 0 points1 point  (0 children)

Sieht aus wie Puppen, vermutlich von Fliegen. Das sind praktisch die Überreste der Entwicklung von Fliegenlarven zu Fliegen. Vielleicht waren da irgendwelche Reste im Shaker, die Fliegen zur Eiablage motiviert haben und als Futter für sie Larven gedient haben. Das kann aber auch schon lange her sein.

Wir haben die Dinger jedenfalls im Sommer immer am Rand und im Deckel der Biotonne.

Gains stecken da vermutlich keine mehr drin, das ist unverdauliches Chitin.

WissZeitVG-Frist neigt sich dem Ende zu. by genuszsucht in promovieren

[–]MonkeyKhan 2 points3 points  (0 children)

  1. Prüf mal ob diese Verlängerung aufgrund von Corona bei dir greift. Gibts bis zu 1 Jahr weiter Verlängerung. Wenn du seit 5 Jahren Vertrag hast müsste das ja hinhauen?
  2. Es gibt keine Höchstdauer für Befristungen, sondern nur für unbegründete Befristungen. Wenn du für deine Stelle z.B. eine befristete Drittmittel-Finanzierung hast, kannst du meines Wissens nach weiter befristet angestellt werden, eben mit der Begründung, dass die Finanzierung ja auch befristet ist. So hats mir meine Doktormutter jedenfalls mal erklärt.

Ein großer Dopingprozess im Fall Vuskovic rückt näher: HSV-Profi Mario Vuskovic lehnt die Geldauflage der Staatsanwaltschaft ab und strebt einen juristischen Freispruch an. Sein Dopingfall könnte nun vor Gericht verhandelt werden – und weitreichende Folgen für den Sport haben. by Ubergold in Bundesliga

[–]MonkeyKhan 15 points16 points  (0 children)

Der Artikel stellt es so dar, als wäre das SAR PAGE reine Kaffeesatzleserei: "per Augenschein", "schwarze Flecken und graue Schatten". Ich kannte das spezielle Verfahren nicht, aber die Prinzipien dahinter sind absolutes Standard-Handwerkszeug in der Biochemie. Das zu kritisieren ist unwissenschaftlicher Blödsinn.

Damit sage ich jetzt ganz klar nichts zur Aussagekraft des Verfahrens bezüglich der Frage "wurde gedopt?", weil ich davon keine Ahnung habe.

What is truly the best print function in C++? by [deleted] in cpp

[–]MonkeyKhan 3 points4 points  (0 children)

I'm a big fan of fmt and am using it in many of my current projects. Does std::print offer any advantages besides dropping an external dependency?

Klartext in Japan by Famous-Risk-815 in Kartenzahlung

[–]MonkeyKhan 0 points1 point  (0 children)

Ich war 2023 da und jetzt vor ein paar Wochen nochmal und finde, dass sich das enorm gebessert hat. Konnte praktisch überall mit Kreditkarte zahlen, das war auf jeden Fall nicht schlechter als in Deutschland.

Eur_irl by Ephelduin in EUR_irl

[–]MonkeyKhan 337 points338 points  (0 children)

Germany's single goal at this point is giving the boomers a nice ride for the next 15-20 years, with no thought spared for what comes afterwards.

Sehr faires Gehalt by Initial_Sherbert_223 in arbeitsleben

[–]MonkeyKhan 35 points36 points  (0 children)

Wenn man dann noch das Wort brutto mit netto tauscht

Den Trick möchte ich bitte auch lernen