Movatterモバイル変換


[0]ホーム

URL:


Translate:
  • Follow Us

  • Pages

  • Find a Job
  • DFP-300×250-1

  • Newsletter Subscription

      Email

      Country


    • Jobboard

    • Suppose you are given the code below – will it compile?

      class X{  public:     void someFunction (X *x)    {      this = x;       }}

      The “this” pointer can not be modified

      The code above willnot compile since assignment to thethis parameter is not allowed in C++. Thethis parameter can not be modified, because it always refers to the current object. Note that trying to modify thethis keyword would not work in Java either.

      Hiring? Job Hunting? Post a JOB or your RESUME on our JOB BOARD >>

      Subscribe to our newsletter for more free interview questions.

      Follow @programmerintvw
      Previous...
      Next...

      Would you like to thankProgrammerInterview.com for being a helpful free resource?Then why not tell a friend about us, orsimply add a link to this page from your webpage using the HTML below.

      Link to this page:

      Please bookmark with social media, your votes are noticed and appreciated:


      [8]ページ先頭

      ©2009-2025 Movatter.jp