From reviews-return-39262-apmail-mesos-reviews-archive=mesos.apache.org@mesos.apache.org Mon Jul 4 16:22:08 2016 Return-Path: X-Original-To: apmail-mesos-reviews-archive@minotaur.apache.org Delivered-To: apmail-mesos-reviews-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E08961986F for ; Mon, 4 Jul 2016 16:22:07 +0000 (UTC) Received: (qmail 86159 invoked by uid 500); 4 Jul 2016 16:22:07 -0000 Delivered-To: apmail-mesos-reviews-archive@mesos.apache.org Received: (qmail 86132 invoked by uid 500); 4 Jul 2016 16:22:07 -0000 Mailing-List: contact reviews-help@mesos.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: reviews@mesos.apache.org Delivered-To: mailing list reviews@mesos.apache.org Received: (qmail 86118 invoked by uid 99); 4 Jul 2016 16:22:07 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 04 Jul 2016 16:22:07 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id 879F02B7BEB; Mon, 4 Jul 2016 16:22:06 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============3088770128520995595==" MIME-Version: 1.0 Subject: Re: Review Request 49424: Added an abstraction os::raw::Argv in stout. From: Jie Yu To: Joris Van Remoortere Cc: Jie Yu , Gilbert Song , mesos Date: Mon, 04 Jul 2016 16:22:06 -0000 Message-ID: <20160704162206.17621.88930@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org/ Auto-Submitted: auto-generated Sender: Jie Yu X-ReviewGroup: mesos X-Auto-Response-Suppress: DR, RN, OOF, AutoReply X-ReviewRequest-URL: https://reviews.apache.org/r/49424/ X-Sender: Jie Yu References: <20160702171132.7972.58047@reviews.apache.org> In-Reply-To: <20160702171132.7972.58047@reviews.apache.org> X-ReviewBoard-Diff-For: 3rdparty/stout/include/stout/os/raw/argv.hpp Reply-To: Jie Yu X-ReviewRequest-Repository: mesos --===============3088770128520995595== MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit > On July 2, 2016, 5:11 p.m., Joris Van Remoortere wrote: > > 3rdparty/stout/include/stout/os/raw/argv.hpp, line 40 > > > > > > It seems like this extra vector and the subsequent copy into the argv array is only necessary because you're supporting structures with an unknown size. > > > > Would this be simpler if you restricted to inputs that support `.size()`? Yes, it would be simpler, but I still have to deal with issues like size() of protobuf repeated field returns an int while other std containers return size_t (unsigned). This is just pointer copies so it won't be too bad. - Jie ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/49424/#review140451 ----------------------------------------------------------- On June 30, 2016, 4:18 p.m., Jie Yu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/49424/ > ----------------------------------------------------------- > > (Updated June 30, 2016, 4:18 p.m.) > > > Review request for mesos and Joris Van Remoortere. > > > Repository: mesos > > > Description > ------- > > Added an abstraction os::raw::Argv in stout. > > > Diffs > ----- > > 3rdparty/stout/include/Makefile.am f10c836c1ac008cc4055741648b5e7dd697e4c1e > 3rdparty/stout/include/stout/os.hpp 53b00932693fba7cf6514da6a519269a904de345 > 3rdparty/stout/include/stout/os/raw/argv.hpp PRE-CREATION > 3rdparty/stout/tests/os_tests.cpp 786da14addf62be5f5270f156fb1e011d3f403e3 > > Diff: https://reviews.apache.org/r/49424/diff/ > > > Testing > ------- > > make check > > > Thanks, > > Jie Yu > > --===============3088770128520995595==--