File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
content/learn/migration-guides/cpp-to-rust Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -54,14 +54,14 @@ It is not a comprehensive guide, but I hope it helps out a C++ developer looking
5454 <td><pre><code class="language-rust">fn add(first: i32, second: i32) -> i32 {
5555 first + second
5656}</code ></pre ></td >
57- <td ><pre ><code class =" language-rust " >int add(int first, int second) {
57+ <td ><pre ><code class =" language-cpp " >int add(int first, int second) {
5858 return first + second;
5959}</code ></pre ></td >
6060 </tr >
6161 <tr >
6262 <td ><strong >Implicit Return</strong ></td >
6363 <td ><pre ><code class =" language-rust " >fn add(a: i32, b: i32) -> i32 { a + b }</code ></pre ></td >
64- <td ><pre ><code class =" language-rust " >auto add(int a, int b) -> int { return a + b; }</code ></pre ></td >
64+ <td ><pre ><code class =" language-cpp " >auto add(int a, int b) -> int { return a + b; }</code ></pre ></td >
6565 </tr >
6666 <tr >
6767 <td ><strong >Immutable Reference</strong ></td >
You can’t perform that action at this time.
0 commit comments