From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on gnuweeb.org X-Spam-Level: X-Spam-Status: No, score=-1.8 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,NO_DNS_FOR_FROM, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from [192.168.1.2] (unknown [101.128.125.123]) by gnuweeb.org (Postfix) with ESMTPSA id 284F3804D1; Fri, 21 Oct 2022 14:34:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1666362862; bh=qfWEqXrEWaF8ywfPQQu6oIHNp3+DGSVKFEeP5RVf+dY=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=R3tO2CR7vOlUmWidJge9OfR/VbQpvtg5a4ZoF3uq+8ba3cwpL3oipU1q525lon0JE VZtZruD09rF8f8ZBOnxWZv1nx426KT/c61dzjfrMUzK6ucxsGlr+iHk+C16NUBThXP TzzauYuea6fyqmkKbZSSEjrS3iyDOtcnWxyd+86pKkWHKiMlDrkKPA67ZHshRBQRwE FeBWrRHsZTl185CUdK+Vj12ZPnGy6lFgtEVjZah0Xqgr22K5kqWlgFuhdQqFJwEVGw i4CSnTxyViW96O4m1OY8ZBYO5VmRgWd/zCVsE7TVHrA2hgmqtjXnIIBs8OBKJvCLd2 MNtKCgZ6+QIUQ== Message-ID: <64f50068-72bc-6f53-17f5-54826bd7947f@gnuweeb.org> Date: Fri, 21 Oct 2022 21:34:16 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.3.3 Subject: Re: [PATCH v3 8/9] enum: Add Platform enumeration Content-Language: en-US To: Ammar Faizi Cc: Alviro Iskandar Setiawan , GNU/Weeb Mailing List References: <20221021134520.701-1-kiizuha@gnuweeb.org> <20221021134520.701-9-kiizuha@gnuweeb.org> <6fb1d238-de6a-325c-8d17-6801ae24c717@gnuweeb.org> <982b723b-5c22-cfe2-6fcf-d0584b8c142d@gnuweeb.org> <90fb2819-443d-2665-e42b-b069e7dbbaff@gnuweeb.org> From: Muhammad Rizki In-Reply-To: <90fb2819-443d-2665-e42b-b069e7dbbaff@gnuweeb.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: On 21/10/2022 21.21, Ammar Faizi wrote: > 1) It reduces the function call and you don't have to import an >    extra library. It's simpler to use and to write, it doesn't >    have to call a function to define the value. > So, you don't want to use extra library or worry about the enum.auto()? If you worry about the enum.auto(), then I just simply declare it as a number. If you don't want to use the extra library then I follow what you want here. > > If using auto generated enum can give us something better at all, > what is that? Tell me. > It just auto generated name to make it readable when printing out or use it as a string value. You can see at gen_temp() in utils.py, I use it as its string name value to choose where the temporary folder to create is. It's simpler, if you want to declare it as an integer, then it's more way complicated because it will use an if statement like the old one does. What do you think?