|
Boost-Build : |
Subject: Re: [Boost-build] [python] imports style
From: Vladimir Prus (ghost_at_[hidden])
Date: 2010-07-14 06:48:14
On Wednesday 14 July 2010 14:27:35 Juraj IvanÄiÄ wrote:
> On 13.7.2010 21:21, Vladimir Prus wrote:
>
> > Is there way to use 'feature.whatever' in the code,
> > as opposed to 'b2.build.feature.whatever'?
>
> Python supports module aliases. The following should work
>
> import b2.build.feature as feature
Ah, nice.
> I personally prefer this approach.
I'll be updating imports to this style whenever I touch them.
Thanks!
-- Vladimir Prus http://vladimir_prus.blogspot.com Boost.Build: http://boost.org/boost-build2
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk