You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Benjamin Bannier <be...@mesosphere.io> on 2018/10/25 10:54:33 UTC

Review Request 69161: Renamed a function argument to not reuse member name.

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69161/
-----------------------------------------------------------

Review request for mesos and Chun-Hung Hsiao.


Repository: mesos


Description
-------

While a function argument shadowing a member variable is perfectly
legal, it is still confusing. In this patch we rename the function
argument to remove one case of such shadowing.


Diffs
-----

  src/resource_provider/storage/provider.cpp db783b53558811081fb2671e005e8bbbd9edbede 


Diff: https://reviews.apache.org/r/69161/diff/1/


Testing
-------

`make check`


Thanks,

Benjamin Bannier


Re: Review Request 69161: Renamed a function argument to not reuse member name.

Posted by Benjamin Bannier <be...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69161/
-----------------------------------------------------------

(Updated Nov. 12, 2018, 9:57 a.m.)


Review request for mesos and Chun-Hung Hsiao.


Changes
-------

Addressed comment from Chun.


Repository: mesos


Description
-------

While a function argument shadowing a member variable is perfectly
legal, it is still confusing. In this patch we rename the function
argument to remove one case of such shadowing.


Diffs (updated)
-----

  src/resource_provider/storage/provider.cpp 2873b1ab300cbb72951b0cca5427ebbc451ae03d 


Diff: https://reviews.apache.org/r/69161/diff/3/

Changes: https://reviews.apache.org/r/69161/diff/2-3/


Testing
-------

`make check`


Thanks,

Benjamin Bannier


Re: Review Request 69161: Renamed a function argument to not reuse member name.

Posted by Benjamin Bannier <be...@mesosphere.io>.

> On Nov. 3, 2018, 12:35 a.m., Chun-Hung Hsiao wrote:
> > src/resource_provider/storage/provider.cpp
> > Line 3065 (original), 3065 (patched)
> > <https://reviews.apache.org/r/69161/diff/2/?file=2103212#file2103212line3065>
> >
> >     Maybe `operationInfo`, or just `operation`?
> >     Also if we go with this naming it would be nice to rename it in the declaration as well.

I went with `operation`.


- Benjamin


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69161/#review210301
-----------------------------------------------------------


On Oct. 25, 2018, 12:54 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/69161/
> -----------------------------------------------------------
> 
> (Updated Oct. 25, 2018, 12:54 p.m.)
> 
> 
> Review request for mesos and Chun-Hung Hsiao.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> While a function argument shadowing a member variable is perfectly
> legal, it is still confusing. In this patch we rename the function
> argument to remove one case of such shadowing.
> 
> 
> Diffs
> -----
> 
>   src/resource_provider/storage/provider.cpp db783b53558811081fb2671e005e8bbbd9edbede 
> 
> 
> Diff: https://reviews.apache.org/r/69161/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 69161: Renamed a function argument to not reuse member name.

Posted by Chun-Hung Hsiao <ch...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69161/#review210301
-----------------------------------------------------------


Fix it, then Ship it!




Thanks for cleaning this up!


src/resource_provider/storage/provider.cpp
Line 3065 (original), 3065 (patched)
<https://reviews.apache.org/r/69161/#comment294958>

    Maybe `operationInfo`, or just `operation`?
    Also if we go with this naming it would be nice to rename it in the declaration as well.


- Chun-Hung Hsiao


On Oct. 25, 2018, 10:54 a.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/69161/
> -----------------------------------------------------------
> 
> (Updated Oct. 25, 2018, 10:54 a.m.)
> 
> 
> Review request for mesos and Chun-Hung Hsiao.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> While a function argument shadowing a member variable is perfectly
> legal, it is still confusing. In this patch we rename the function
> argument to remove one case of such shadowing.
> 
> 
> Diffs
> -----
> 
>   src/resource_provider/storage/provider.cpp db783b53558811081fb2671e005e8bbbd9edbede 
> 
> 
> Diff: https://reviews.apache.org/r/69161/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>