Skip to content

Commit

Permalink
Update doc/manual_experimental.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Araq authored Aug 12, 2023
1 parent 522d936 commit 70be846
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/manual_experimental.md
Original file line number Diff line number Diff line change
Expand Up @@ -2438,5 +2438,5 @@ proc invoke(f: NimFunctor; n: int) {.member: "operator ()('2 #2)".} =
proc `()`(f: NimFunctor; n:int) {.importcpp: "#(@)" .}
NimFunctor()(1)
```
Notice we are also using the overload of `()` to have the same semantics in Nim, but on the `importcpp` we are importing the functor as a function.
Notice we use the overload of `()` to have the same semantics in Nim, but on the `importcpp` we import the functor as a function.
This allows to easy interop with functions that accepts for example a `const` operator in its signature.

0 comments on commit 70be846

Please sign in to comment.