List comprehension rebinds names even after scope of comprehension. Is this right?

List comprehensions leak the loop control variable in Python 2 but not in Python 3. Here’s Guido van Rossum (creator of Python) explaining the history behind this: We also made another change in Python 3, to improve equivalence between list comprehensions and generator expressions. In Python 2, the list comprehension “leaks” the loop control variable … Read more

Why does WPF support binding to properties of an object, but not fields?

Binding generally doesn’t work to fields. Most binding is based, in part, on the ComponentModel PropertyDescriptor model, which (by default) works on properties. This enables notifications, validation, etc (none of which works with fields). For more reasons than I can go into, public fields are a bad idea. They should be properties, fact. Likewise, mutable … Read more

How to enable assembly bind failure logging (Fusion) in .NET

Add the following values to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Fusion Add: DWORD ForceLog set value to 1 DWORD LogFailures set value to 1 DWORD LogResourceBinds set value to 1 DWORD EnableLog set value to 1 String LogPath set value to folder for logs (e.g. C:\FusionLog\) Make sure you include the backslash after the folder name and that the Folder … Read more