Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #64692

Re: Python declarative

Path csiph.com!usenet.pasdenom.info!dedibox.gegeweb.org!gegeweb.eu!nntpfeed.proxad.net!proxad.net!feeder1-2.proxad.net!usenet-fr.net!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <matej@ceplovi.cz>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.001
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'python,': 0.02; 'xml,': 0.05; 'subject:Python': 0.06; 'bits': 0.09; 'forms,': 0.09; 'pgp': 0.09; 'xml.': 0.09; 'python': 0.11; 'wrote': 0.14; 'question.': 0.14; '(gnu/linux)': 0.16; '-----begin': 0.16; '-----end': 0.16; 'gnupg': 0.16; 'hash:': 0.16; 'sha1': 0.16; 'language': 0.16; 'wrote:': 0.18; 'message-----': 0.19; 'seems': 0.21; 'code,': 0.22; 'header:User-Agent:1': 0.23; 'helper': 0.24; 'pass': 0.26; 'signed': 0.27; 'header:In-Reply-To:1': 0.27; 'rest': 0.29; 'thus': 0.29; 'xml': 0.29; '(which': 0.31; 'code': 0.31; 'skip:i 60': 0.31; 'figure': 0.32; 'classes': 0.35; 'common': 0.35; 'but': 0.35; 'there': 0.35; 'functions.': 0.36; 'right?': 0.36; 'version:': 0.36; 'useful': 0.36; 'wrong': 0.37; 'problems': 0.38; 'easiest': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'full': 0.61; 'from:charset:utf-8': 0.61; 'simple': 0.61; 'header:Message-Id:1': 0.63; 'more': 0.64; 'rendering': 0.68; 'expressive': 0.84; 'scratch,': 0.84
To python-list@python.org
Subject Re: Python declarative
In-Reply-To <CAPTjJmo+EuY439wB0C8or+ZAcYeNR844HAKwL3i2+55dDE8LNA@mail.gmail.com>
References <mailman.5529.1389805825.18130.python-list@python.org> <8fde6d34-47c5-49a1-a6d0-9ffe3df2d401@googlegroups.com> <CAPTjJmokZUHta7Y3x_=6eUjKpv2Td2iaqro1su7NuLo+gfzwag@mail.gmail.com> <lbtb9r$ljd$1@ger.gmane.org> <CAPTjJmo+EuY439wB0C8or+ZAcYeNR844HAKwL3i2+55dDE8LNA@mail.gmail.com>
From Matěj Cepl <mcepl@redhat.com>
Date Fri, 24 Jan 2014 17:28:41 +0100
User-Agent slrn/1.0.1 (Linux)
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding 8bit
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.5947.1390580930.18130.python-list@python.org> (permalink)
Lines 30
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1390580930 news.xs4all.nl 2970 [2001:888:2000:d::a6]:52161
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:64692

Show key headers only | View raw


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 2014-01-24, 11:18 GMT, you wrote:
> Write your rendering engine as a few simple helper functions, 
> and then put all the rest in as code instead of XML. The 
> easiest way to go about it is to write three forms, from 
> scratch, and then look at the common parts and figure out 
> which bits can go into helper functions.

Perhaps what's missing is full acknowledgment that Python has 
dual-inheritance and thus it can have mixin classes (which seems 
to me to be the only useful use of dual inheritance). You know 
you can have mixins in Python, right?

Also, I wrote my share of XML parsing/writing code, but more and 
more I am persuaded that if the answer is “XML” then there is 
some wrong with the question. Python is a way more expressive 
language than XML, so it is almost always more useful to write 
in Python, than to pass any problems to XML.

Matěj

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)

iD8DBQFS4pS54J/vJdlkhKwRApdcAJ48PRgDz6ccnq1YFD9zx8EDDH3JjgCghU2x
3CV+D0LvquzgYRux2GslZ0E=
=Y3/F
-----END PGP SIGNATURE-----

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Python declarative Sergio Tortosa Benedito <sertorbe@gmail.com> - 2014-01-15 18:02 +0100
  Re: Python declarative Francesco Bochicchio <bieffe62@gmail.com> - 2014-01-17 06:22 -0800
    Re: Python declarative Francesco Bochicchio <bieffe62@gmail.com> - 2014-01-19 23:25 -0800
  Re: Python declarative sertorbe@gmail.com - 2014-01-17 06:47 -0800
    Re: Python declarative Tim Roberts <timr@probo.com> - 2014-01-18 13:13 -0800
  Re: Python declarative sertorbe@gmail.com - 2014-01-19 02:27 -0800
  Re: Python declarative sertorbe@gmail.com - 2014-01-22 12:38 -0800
  Re: Python declarative Asaf Las <roegltd@gmail.com> - 2014-01-22 13:16 -0800
    Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-23 13:29 +1100
    Re: Python declarative Terry Reedy <tjreedy@udel.edu> - 2014-01-22 23:08 -0500
    Re: Python declarative "Frank Millman" <frank@chagford.com> - 2014-01-24 11:21 +0200
      Re: Python declarative Rustom Mody <rustompmody@gmail.com> - 2014-01-24 01:53 -0800
        Re: Python declarative "Frank Millman" <frank@chagford.com> - 2014-01-24 15:06 +0200
    Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-24 22:18 +1100
    Re: Python declarative "Frank Millman" <frank@chagford.com> - 2014-01-24 14:49 +0200
    Re: Python declarative Burak Arslan <burak.arslan@arskom.com.tr> - 2014-01-24 15:40 +0200
    Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-25 00:55 +1100
    Re: Python declarative Matěj Cepl <mcepl@redhat.com> - 2014-01-24 17:28 +0100
    Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-25 03:33 +1100
      Re: Python declarative sertorbe@gmail.com - 2014-01-24 10:51 -0800
    Re: Python declarative "Frank Millman" <frank@chagford.com> - 2014-01-25 09:18 +0200
      Re: Python declarative Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-01-26 02:33 +0000
        Re: Python declarative Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-01-26 02:45 +0000
          Re: Python declarative Asaf Las <roegltd@gmail.com> - 2014-02-02 18:17 -0800
        Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-26 14:38 +1100
        Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-26 15:06 +1100
          Re: Python declarative Rustom Mody <rustompmody@gmail.com> - 2014-01-25 20:47 -0800
            Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-26 16:23 +1100
              Re: Python declarative Rustom Mody <rustompmody@gmail.com> - 2014-01-26 00:05 -0800
                Re: Python declarative "Frank Millman" <frank@chagford.com> - 2014-01-26 11:12 +0200
                Re: Python declarative Rustom Mody <rustompmody@gmail.com> - 2014-01-26 06:36 -0800
          Re: Python declarative Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-01-26 12:05 +0000
        Re: Python declarative "Frank Millman" <frank@chagford.com> - 2014-01-26 08:03 +0200
          Re: Python declarative Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-01-26 12:21 +0000
    Re: Python declarative Chris Angelico <rosuav@gmail.com> - 2014-01-25 18:33 +1100
    Re: Python declarative matej@ceplovi.cz (Matěj Cepl) - 2014-01-25 12:23 +0100
  Re: Python declarative Asaf Las <roegltd@gmail.com> - 2014-01-24 04:04 -0800

csiph-web