Run Code
|
API
|
Code Wall
|
Users
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
RVO hota hai bhenchod
Language:
Ada
Assembly
Bash
C#
C++ (gcc)
C++ (clang)
C++ (vc++)
C (gcc)
C (clang)
C (vc)
Client Side
Clojure
Common Lisp
D
Elixir
Erlang
F#
Fortran
Go
Haskell
Java
Javascript
Kotlin
Lua
MySql
Node.js
Ocaml
Octave
Objective-C
Oracle
Pascal
Perl
Php
PostgreSQL
Prolog
Python
Python 3
R
Rust
Ruby
Scala
Scheme
Sql Server
Swift
Tcl
Visual Basic
Layout:
Vertical
Horizontal
#include <vector> #include <numeric> #include <iostream> struct loud { loud() {} //{ std::cout << "loud()\n"; } ~loud() {} //{ std::cout << "~loud()\n"; } loud(loud const&) { std::cout << "fail!\n"; } }; using vec_t = std::vector<loud>; struct Foo { vec_t v; Foo(vec_t _v) : v(std::move(_v)) {} }; Foo getBigFoo() { vec_t v(1); return {std::move(v)}; // Expecting RVO to happen here. } int main() { auto foo = getBigFoo(); }
cl.exe
Show compiler warnings
[
+
] Compiler args
[
+
]
Show input
Compilation time: 1.4 sec, absolute running time: 0.04 sec, absolute service time: 1.47 sec
edit mode
|
history
|
discussion