On Fri, Apr 11, 2008 at 5:49 PM, Rajeev J Sebastian <[EMAIL PROTECTED]> wrote: > On Fri, Apr 11, 2008 at 8:56 PM, Simon Willison <[EMAIL PROTECTED]> wrote: > > > > def render(self, context): > > "Display stage -- can be called many times" > > if not isinstance(context, Context): > > context = Context(context) > > return self.nodelist.render(context) > > > > This is backwards compatible and would make the template system that > > tiny bit nicer to use. > The problem with this is that we have to pass an instance of a > subclass of Context, rather than something that has the interface of a > Context. Is it a good idea ?
Why not use the opposite test and check for instances of dict? -- Patryk Zawadzki PLD Linux Distribution --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-developers?hl=en -~----------~----~----~----~------~----~------~--~---