Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8478673
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T18:48:36+00:00 2026-06-10T18:48:36+00:00

Suppose I have a type T: typedef … T; and then I have these

  • 0

Suppose I have a type T:

typedef ... T;

and then I have these functions:

T f11();
T& f12();
T&& f13();
const T f21();
const T& f22();
const T&& f23();

and then call them like this:

auto x11 = f11();
auto x12 = f12();
auto x13 = f13();
auto x21 = f21();
auto x22 = f22();
auto x23 = f23();

From which sections/clauses of the C++11 standard can it be deduced the equivalent non-auto declarations of x11..x23?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T18:48:37+00:00Added an answer on June 10, 2026 at 6:48 pm

    It is in §7.1.6.4 auto specifier. In your examples of function return types, the rules of template argument deduction apply.

    Paraquoting the relevant example from the standard:

    const auto &i = expr;

    The type of i is the deduced type of the parameter X in the call f(expr) of the following invented function template:

    template <class AUTO> void f(const AUTO& X);

    So in your examples, the types of all your variables x11 to x23 are deduced as T.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Suppose I have a user defined type: CREATE OR REPLACE TYPE TEST_TYPE AS OBJECT
Suppose I have any image(say passport type images where the background will be same
Suppose I have some class which has a property actor_ of type Actor .
Suppose I have something like this: if ($command === 'txt') { header('Content-type: text/plain;charset=utf-8'); echo
Suppose I have a form like this: Name:<input type=text name=xxx id=name/> Type:<select> <option>xx</option> <option>xx</option>
Suppose I have a table events {id, userid, create_time, country, type, page, browser} I
suppose I have a type defined as type value = None | Int of
Suppose I have a content type, Folder, with 4 items. + MyObject - Child1
Suppose I have a data type enum TreeTypes { TallTree, ShortTree, MediumTree } .
Suppose I have the following class X { typedef some_numeric_type my_type; } How to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.