I'm refining my code and noticed that at some places I had optional parameters with the default value of an empty string. I changed that to a default value from the class for empty string and guess what! Apparently there's a difference between empty quotation marks and string.Empty. What the duck?! (typo intended)  private void Khaboom(String parameter = "") { ... }  private void Bazinga(String parameter = String.Empty) { ... }   Can someone explain to me why the duck does Khaboom work while Bazinga doesn't?!  The error message whines this:      Default parameter value for 'parameter' must be a compile-time constant.    Well... It is!
In .NET why is String.Empty read only instead of a constant? I'm just wondering if anyone knows what the reasoning was behind that decision.
Do the SSH or FTP protocols tell the server to which domain I am trying to connect? When using the ssh or ftp commands from the Bash shell, does the server that I am connecting to learn of the domain name used? I understand that the domain name is locally translated into an IP address via DNS. In HTTP, after that happens, the server is told the original domain name as well in order to serve the correct page, or to present the correct TLS cert (SNI).  host serverfault.com GET /   Does a similar phenomenon happen when connecting to ssh or ftp?  I ask because I am  trying to ssh into a server (GoDaddy webhosting) which expects a domain name, but is not letting me in when I try to connect via user@IPaddress as the DNS is not yet moved to the GoDaddy IP address. This is regards to the lorentz invariance of a classical scalar field theory. We assume that the action which is $S= \int d^4 x \mathcal{L}$, is invariant under a Lorentz transformation. How do you prove that the integration measure $d^4 x$ is Lorentz invariant. How to avoid using sudo when working in /var/www? I want to stop having to use sudo everytime I work in /var/www. How can I do that? I simply want to put all of my sites into this directory and work with them without too much pain. On the left is the normal map generated by the Bevel node. On the right is an unbeveled cube with the Bevel node in action. I wish to convert this to a BW map where The edges/gradients are highlighted and the rest isn't. Does anyone know if this can be achieved with more nodes? What do you call a person that won’t act? What would you call a person that just stands by and won't act? Is kind of acting like a spectator when in reality that person should do something?  I know there is a word for this because I knew what it was a few hours ago but now I can’t remember it. How do I set my DNS when resolv.conf is being overwritten? Most of the info I see online says to edit /etc/resolv.conf, but any changes I make there just get overridden.  $ cat /etc/resolv.conf  # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8) #     DO NOT EDIT THIS FILE BY HAND --  #     YOUR CHANGES WILL BE OVERWRITTEN nameserver 127.0.1.1   It seems that 127.0.1.1 is a local instance of dnsmasq. The dnsmasq docs say to edit /etc/resolv.conf. I tried putting custom nameservers in /etc/resolv.conf.d/base, but the changes didn't show up in /etc/resolv.conf after running sudo resolvconf -u.  FYI, I don't want to change DNS on a per-connection basis, I want to set default DNS settings to use for all connections when not otherwise specified.  UPDATE:  I answered this question myself:   I think it's the best solution since:   It works. It requires the least amount of changes and It still works in conjunction with dnsmasq's DNS cache, rather than bypassing it. Regarding the recalc in question rep increase what happens due to the cap? Prove that if $A$ is a set with $m$ elements, $B$ is a set with $n$ elements, and $A \cap B = \emptyset$, then $A \cup B$ has $m+n$ elements. Is there a way to export my artwork as PDF so that it has a transparent background? Something like exporting objects only... whenever I try to save my .ai as pdf, it always comes with a full white background. If I try to save as eps, I get a chunky white background (where it has white rectangles behind the artwork only where the artwork exists, so there are transparent chunks).  If I export as png, I get an image like what I'm looking for. Is there any way to do that in a vector format? What do Pentax and Sigma DSLRs offer that differs from Canon and Nikon? We have a question and answers outlining the . I'm interested in the other DSLR makers, and how the cameras they make compare in terms of significant features, system design philosophy, and unique or interesting photographic capabilities enabled or made easier by these cameras. Likewise, what such things are not handled as well?  Take "the big two have more market share" and the associated advantages of availability, accessibility, and third-party support and documentation .  I'm not interested here in compact cameras, interchangeable-lens cameras with electronic viewfinders, or in rangefinders. (If you're interested in that, though, see )  P.S.: Differences in lens lineups are covered at Enumerate or list all variables in a program of [your favorite language here] A friend asked me last week how to enumerate or list all variables within a program/function/etc. for the purposes of debugging (essentially getting a snapshot of everything so you can see what variables are set to, or if they are set at all). I looked around a bit and found a relatively good way for Python:   #!/usr/bin/python                                                                                                                                                                                                                            foo1 = "Hello world" foo2 = "bar" foo3 = {"1":"a",         "2":"b"} foo4 = "1+1"  for name in dir():     myvalue = eval(name)     print name, "is", type(name), "and is equal to ", myvalue   which will output something like:   __builtins__ is &lt;type 'str'&gt; and is equal to  &lt;module '__builtin__' (built-in)&gt; __doc__ is &lt;type 'str'&gt; and is equal to  None __file__ is &lt;type 'str'&gt; and is equal to  ./foo.py __name__ is &lt;type 'str'&gt; and is equal to  __main__ foo1 is &lt;type 'str'&gt; and is equal to  Hello world foo2 is &lt;type 'str'&gt; and is equal to  bar foo3 is &lt;type 'str'&gt; and is equal to  {'1': 'a', '2': 'b'} foo4 is &lt;type 'str'&gt; and is equal to  1+1   I have so far found a partial way in PHP (courtesy of ) but it only lists all variables and their types, not the contents:   &lt;?php // create a few variables $bar = 'foo'; $foo ='bar'; // create a new array object $arrayObj = new ArrayObject(get_defined_vars()); // loop over the array object and echo variables and values for($iterator = $arrayObj-&gt;getIterator(); $iterator-&gt;valid(); $iterator-&gt;next())         {         echo $iterator-&gt;key() . ' =&gt; ' . $iterator-&gt;current() . '&lt;br /&gt;';         } ?&gt;   So I put it to you: how do you list all variables and their contents in your favorite language?    Edit by : I propose this question follows the spirit of a little "". If you do not agree, just edit and remove the tag and the link. Backup and restore settings in Texstudio Does someone know, how to save all the settings of Texstudio and restore them in a simple way?  Thank you in advance! Chrome browser will not connect to intranet web addresses showing $\psi: R\to \mathbb C$ is ring isomorphism. How to design partitions for SSHD? Is re-projection needed from SRID 4326 (WGS 84) to SRID 4269 (NAD 83)? I have US census data against state boundaries stored as  SRID 4269, in an MSSQL DB.  The input data used for calculations against that dataset is stored as SRID 4326.  As far as I can infer from the , SRID 4269 is just a subset of SRID 4326 and no coordinate re-projection is necessary.  Do I actually need to re-project from SRID 4326 to SRID 4269, provided that the input data is always within the bounds of the SRID 4269? Does Python SciPy need BLAS? Negative probabilities in quantum physics How do I prove equality of x and y? If $0\leq x,y\leq\frac{\pi}{2}$ and $\cos x +\cos y -\cos(x+y)=\frac{3}{2}$, then how can I prove that $x=y=\frac{\pi}{3}$? Your help is appreciated.I tried various formulas but nothing is working. How to detect if a function is called as constructor? Given a function:  function x(arg) { return 30; }   You can call it two ways:  result = x(4); result = new x(4);   The first returns 30, the second returns an object.  How can you detect which way the function was called inside the function itself?  Whatever your solution is, it must work with the following invocation as well:  var Z = new x();  Z.lolol = x;  Z.lolol();   All the solutions currently think the Z.lolol() is calling it as a constructor.