diff options
author | Kjell Ahlstedt <kjellahlstedt@gmail.com> | 2020-06-27 10:34:17 +0200 |
---|---|---|
committer | Kjell Ahlstedt <kjellahlstedt@gmail.com> | 2020-06-27 10:34:17 +0200 |
commit | 0aa9ed933ec9f97a27a16cbd530d5ad0bb8452dd (patch) | |
tree | e4fdcd241a97d9d1a361986f99b8454fd808f4a9 | |
parent | c0d4c0a4ded40a068107c42f2ae6413f6bb40855 (diff) | |
download | sigc++-0aa9ed933ec9f97a27a16cbd530d5ad0bb8452dd.tar.gz |
docs/docs/manual/libsigc_manual.xml: Fix description of sigc::retype()
Although sigc::retype() is a template function, no template parameters
shall be specified when it's called.
-rw-r--r-- | docs/docs/manual/libsigc_manual.xml | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/docs/docs/manual/libsigc_manual.xml b/docs/docs/manual/libsigc_manual.xml index fde9257..9a181e3 100644 --- a/docs/docs/manual/libsigc_manual.xml +++ b/docs/docs/manual/libsigc_manual.xml @@ -406,10 +406,8 @@ myaliendetector.signal_detected.connect( sigc::hide<std::string>( sigc::pt <para>A similar topic is retyping. Perhaps you have a signal that takes an <literal remap="tt">int</literal>, but you want to connect a function that takes a <literal remap="tt">double</literal>.</para> - <para>This can be achieved with the <literal remap="tt">sigc::retype</literal> template. <literal remap="tt">retype</literal> has template arguments - just like <literal remap="tt">sigc::signal</literal> - return value, signal types.</para> - - <para>It's a function template that takes a <literal remap="tt">sigc::slot</literal>, and returns a <literal remap="tt">sigc::slot</literal>. eg.</para> + <para>This can be achieved with the <literal remap="tt">sigc::retype()</literal> template. + It takes a <literal remap="tt">sigc::slot</literal>, and returns a <literal remap="tt">sigc::slot</literal>. eg.</para> <programlisting> void dostuff(double foo) @@ -418,11 +416,11 @@ void dostuff(double foo) sigc::signal<void(int)> asignal; -asignal.connect( sigc::retype<void(int)>( sigc::ptr_fun(&dostuff) ) ); +asignal.connect( sigc::retype( sigc::ptr_fun(&dostuff) ) ); </programlisting> - <para>If you only want to change the return type, you can use <literal remap="tt">sigc::retype_return</literal>. - <literal remap="tt">retype_return</literal> needs only one template argument.</para> + <para>If you only want to change the return type, you can use <literal remap="tt">sigc::retype_return()</literal>. + <literal remap="tt">retype_return()</literal> needs one template argument, the new return type.</para> </sect1> </chapter> |