[elbe-devel] [PATCH 2/5] Add ISO files options for source cdroms

Torben Hohn torben.hohn at linutronix.de
Mon Aug 5 11:11:45 CEST 2019


On Thu, Jul 18, 2019 at 02:11:10PM +0200, Kurt Kanzenbach wrote:
> Hi,
> 
> On Wed, Jul 17, 2019 at 10:49:56AM +0200, Olivier Dion wrote:
> >
> > On 2019-07-17T09:38:09+0200, Kurt Kanzenbach wrote:
> >
> > > Why not use hashes consistently? I'd prefer something like
> >
> > >  str_type = encoding[iso_options[opt_name]["str_type"]]
> >
> > > > +    if len(text) > iso_options[opt_name][1]:
> >
> > >  if len(text) > iso_options[opt_name]["len"]:
> >
> > > and so on. It makes it easier to read.
> >
> > Old C habit I guess.  I can either change it to a dict if you want.
> 
> Next time.

A dict would make the initialisation bad to read.

we want
https://docs.python.org/2/library/collections.html#collections.namedtuple

for such a thing.

that would be a C habit. i doubt, that you would prefer an array of ints or
pointers over a struct ;)

> 
> Thanks,
> Kurt



> _______________________________________________
> elbe-devel mailing list
> elbe-devel at linutronix.de
> https://lists.linutronix.de/mailman/listinfo/elbe-devel


-- 
Torben Hohn
Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-Mühlhofen
Phone: +49 7556 25 999 18; Fax.: +49 7556 25 999 99

Hinweise zum Datenschutz finden Sie hier (Informations on data privacy 
can be found here): https://linutronix.de/kontakt/Datenschutz.php

Linutronix GmbH | Firmensitz (Registered Office): Uhldingen-Mühlhofen | 
Registergericht (Registration Court): Amtsgericht Freiburg i.Br., HRB700 
806 | Geschäftsführer (Managing Directors): Heinz Egger, Thomas Gleixner



More information about the elbe-devel mailing list