• Kirill Smelkov's avatar
    context: tests: Don't compare .done() by "is" · 20761c55
    Kirill Smelkov authored
    This continues 2c8063f4 (*: Channels must be compared by ==, not by "is"
    even for nilchan) and changes comparision of .done() for different
    contexts from "is" to ==.
    
    The reason is that soon we are going to move contexts into C, and this
    way in context tree there potentially can be PyCtx -> CCtx -> PyCtx
    chains, and while all those contexts could have the same C-level channel,
    it would be difficult to propagate the knowledge that Python-level
    pychan wrapper should be also exactly the same.
    
    We already treat channel objects as pointers and require to compare them
    by ==, so there should be no loss here. However to keep performance of
    repeated
    
    	select(
    	    ctx.done(),
    	    ...
    	)
    
    we continue to require that .done() for a particular python context
    object returns exactly the same channel object every time.
    20761c55
Name
Last commit
Last update
3rdparty/include/linux Loading commit data...
golang Loading commit data...
gpython Loading commit data...
.gitignore Loading commit data...
CHANGELOG.rst Loading commit data...
COPYING Loading commit data...
MANIFEST.in Loading commit data...
README.rst Loading commit data...
pyproject.toml Loading commit data...
setup.py Loading commit data...
tox.ini Loading commit data...
trun Loading commit data...