In the example given in §14.4.1 "Accelerated C++, A. Koenig and B. E. Moo" I have problems if I implement the template specialization like it is presented in the book.  The minimum working example (top down) is:  g++ str.cpp main.cpp     main.cpp:  #include "str.hpp"  int main(int argc, char** argv)  {      Str n;                //def      return 0;  }     str.hpp:  #ifndef GUARD_str_h #define GUARD_str_h  #include &lt;vector&gt;  #include "ptr.hpp"  class Str {     public:         Str(): data(new std::vector&lt;char&gt;) { }     private:         Ptr&lt; std::vector&lt;char&gt; &gt; data; }; #endif     str.cpp:  #include "str.hpp"     ptr.hpp:  #ifndef GUARD_ptr_h #define GUARD_ptr_h  #include &lt;vector&gt;   template&lt;class T&gt; T* clone(const T* tp); template&lt;&gt; std::vector&lt;char&gt;* clone(const  std::vector&lt;char&gt;* vp);  template &lt;class T&gt; class Ptr {     public:         Ptr(): refptr(new size_t(1)), p(0) { }         Ptr(T* t): refptr(new size_t(1)), p(t) { }         ~Ptr();     private:         T* p;         size_t* refptr; };  #include "ptr.cpp" #endif     ptr.cpp:  template&lt;class T&gt; Ptr&lt;T&gt;::~Ptr() {     if (--*refptr == 0) {         delete refptr;         delete p;     } }  template&lt;class T&gt; T* clone(const T* tp) {     return tp-&gt;clone(); }  template&lt;&gt; std::vector&lt;char&gt;* clone(const std::vector&lt;char&gt;* vp) {     return new std::vector&lt;char&gt;(*vp); }   The problem is the last template specialization   template&lt;&gt; std::vector&lt;char&gt;*   It gives an   multiple definition of 'std::vector&lt;char...&gt;   error. It only works with   template&lt;&gt; inline std::vector&lt;char&gt;*   1) I do not fully understand why I need "inline".  2) Is this an error in the book? I tried to put this template specialization in the ptr.hpp file. Again, it only works with "inline".  Thanks to all who can put some light on this issue.
Quote from :     The only portable way of using templates at the moment is to implement them in header files by using inline functions.   Why is this?  (Clarification: header files are not the only portable solution. But they are the most convenient portable solution.)
What is the Total Reputation field on Area51? What does the total reputation field on Area51 represent?  It's obviously not the total of the user's reputation on the various sites, as that is the number listed as user reputation. What does the actual phrase above mean? Can we know the fundamental nature of space and time? What sci-fi work first showed a weapon of galactic-scale mass destruction? Currently, I have two examples in my mind:   Halo (Halo video game series; 2001): Can destroy all sentient life within three galactic radii The Moment/ Eye of Discord/ Galaxy Eater (Doctor Who (2005) TV series; 2013): Can destroy entire galaxy within a moment   What sci-fi work first showed a weapon of galactic-scale mass destruction? I frequently create labels that follow the same format: white text on a 75% opaque black background, with 10px of margin around the text. Currently, I have to manually build these labels, which takes a lot of work.  In one method, I write the text, figure out its height and width, then create a separate rectangle and place it behind it. This takes a lot of clicking around for every label.  In the other method, I draw out a text box, select it directly, give it the correct background and margins, and then insert the text. However, I must then resize the box manually, meaning more clicking around and greater imprecision. There doesn't seem to be a way to directly select a text box once it has text inside it.  I tried using the script contained in  to resize the text box to the content, but it only resizes the box vertically, and removes my color and margins.  Does anyone have suggestions on how to resolve these problems, or for a better method? I'm using CS3. Is being good at mathematic contests necessary to pursue a career in mathematics or physics? I am extremely poor in solving a problem quickly, which leaves me doing badly in olympiads and other contests. But, if I just don’t give up on a problem, no matter how much time it takes, I usually end up solving it. To have a future in mathematics or physics, is it necessary for me to excel at contests, because these days children excelling at contests have an advantage over those who don’t (not complete advantage, but advantage nonetheless)? I'm new to blender and have this issue: I'm using the "Industry Compatible" keymap. In "Edit Mode" the keys 1, 2 and 3 swap between vertex, edge and face select - Great!  Now i want to customize it, so i'm adding a new preset "My keymap". As far as i understand this now is based on the "Industry Compatible" keympap and everything works accordingly. But if i close and start blender again, the 1, 2 and 3-key aren't working anymore. I need to go back to the preferences, set the "Industry Compatible" keymap and then set back to "My keymap". Then the 1, 2 and 3-key work again as expected.  This is reproduceable on the last Blender 2.8 version on several different machines. Am i doing something wrong? Is this a bug? Derived template-class access to base-class member-data Adding Basemaps from Google or Bing in QGIS ArcGIS Desktop has the option of using basemaps from ArcGIS Online. Does QGIS have any such options? Ask question post button remains disabled I've noticed this twice in the last ~2 weeks or so. The &quot;post your question&quot; button can remain disabled for some reason even when your question is shown as &quot;ready to publish&quot;. I.e., you've gotten to the &quot;review&quot; page after the initial edit. If I remember correctly, one case was on Stack Overflow, and the other was on . I'm not sure what exact scenario leads up to this. I haven't paid attention to the button until the last step when I'm ready to click it. The workaround has been to reload the page. (I copied my content for safe-keeping first.) This works, and the button then shows up as active. Afterwards, however, on both occasions, it forced me through the &quot;are you a human&quot; verification.  Update - this question itself did not exhibit this, nor did it do the .  Update - I'm using Chrome on Windows and am not sure what version it was when this happened.  It has  installed, but there aren't any scripts for any Stack Exchange sites.  It has  installed.  The virus scanner on the PC I probably was using was How to change default window background color in Windows 10? In Windows 7 and Windows XP it was very easy to change the default background color of all windows to whatever you want. Staring at white window backgrounds all day is hard on the eyes. Once changed, ALL windows of all apps would conform to the custom color as long as the apps allowed the windows bg to be invoked. So for example it worked great in Notepad and many other apps.   Then the geniuses at M$ decided that this feature was no longer needed in Windows 8, and removed it. There were some reg hacks, but nothing standard. I remember reading that the feature would be coming back in Windows 10, but I'm not finding this to be the case. The only [partial/broken] way I have found to be able to do this is to tweak the following registry keys:  [HKEY_CURRENT_USER\Control Panel\Colors] "Window"="227 221 191"  [HKEY_CURRENT_USER\Control Panel\Desktop\Colors] "Window"="227 221 191"   When I changed those keys to my chosen soothing color and rebooted, it worked ONE TIME. After every reboot thereafter, all the white backgrounds are back AND YET those registry keys still have my custom RGB codes. I really hate Microsoft right now, but that aside, is there any solid way to change windows 10 bg colors and make it stick?  Important: In Settings -> Personalization -> Colors, none of that changes windows backgrounds. Already tried.   I am using Windows 10 Enterprise Version 1511 Build 10586.3.  UPDATE: I rebooted again and the bg colors work correctly...but later in the day all the window bgcolors were back to white again. Windows 8.1 had the exact same bug. My conclusion is that the reg hack "works" but only intermittently. Is this simply a MS bug? Or is there a better answer/solution? Disable password access through SSH? I'm setting up a server for backing up my desktop box remotely. I want to prevent remote password access to the server, permitting only users with private keys (AKA my desktop box) to access it. How can I block remote password access while allowing physical password access to the server? How do we know an $ \aleph_1 $ exists at all? I have two questions, actually. The first is as the title says: how do we know there exists an infinite cardinal such that there exists no other cardinals between it and $ \aleph_0 $? (We would have to assume or derive the existence of such an object before we label it something like $ \aleph_1 $.)  My second question is, can we say for certain if there's any limit to the number of cardinals existing between $ \aleph_0 $ and continuum (i.e. $ 2^{\aleph_0} $)? I mean, how could we know that there&#39;s not an infinite number of cardinals between the two - perhaps even more than $ \aleph_0 $? Are delphi variables initialized with a value by default? I'm new to Delphi, and I've been running some tests to see what object variables and stack variables are initialized to by default:  TInstanceVariables = class   fBoolean: boolean; // always starts off as false   fInteger: integer; // always starts off as zero   fObject: TObject; // always starts off as nil end;   This is the behaviour I'm used to from other languages, but I'm wondering if it's safe to rely on it in Delphi?  For example, I'm wondering if it might depend on a compiler setting, or perhaps work differently on different machines.  Is it normal to rely on default initialized values for objects, or do you explicitly set all instance variables in the constructor?  As for stack (procedure-level) variables, my tests are showing that unitialized booleans are true, unitialized integers are 2129993264, and uninialized objects are just invalid pointers (i.e. not nil).  I'm guessing the norm is to always set procedure-level variables before accessing them? Show that if $ \ A \cup B = A$ and $ \ A\cap B = A$ then $ \ A = B$ Question:  Show that if $ \ A \cup B = A$ and $ \ A\cap  B = A$ then $ \ A = B$  My attempt:  Proof by contradiction:  Assume $ \ A \cup B = A$ and $ \ A\cap  B = A$ and $ \ A \neq B$   Case 1: $ \exists \ x \in A, x\notin B$  If $ x \in A \implies x\in A \cap B \implies x \in A \ and \  x\in B  \implies x\in B$, a contradiction.   Case 2: $ \exists \ x \in B, x\notin A$  If $ \ x \in B \implies x\in A \cup B \implies x\in A$, since $ \ A \cup B = A$. Contradiction.   Is this approach correct? Could someone please show me how to do a direct proof? How can continue the equation of the rectangle red in next line?   \documentclass[11pt,a4paper,twocolumn]{article}  ...  \begin{equation*}     \left| \dot{r} \right| =     \sqrt{{- \, {e}^{-t} \left( \cos t + \sin t \right)}^{2} \, + \, {{e}^{-t} \left( \cos t + \sin t \right)}^{2} \, + \, {(- \, {e}^{-t})}^{2}} \end{equation*} Add a custom curve mapping property for an add-on? Question The title says it all. I want to be able to make this in Blender's UI, and sample it at specific points :  Problem There is very insufficient documentation on this, and I can't find any examples for how to create a . I have worked with templates before, and , but it requires a curve mapping prop. Extra Info I found a few threads about this, and one gives me the impression that this cannot be done at all, but it is also very old.   This similar question has been asked here before, but it didn't even get a comment:  Is this even possible to access in python (as in only accessible in C)? Pollinator abundance---sampled two years, fixed or random effect? I'm trying to construct several GLMMs with my thesis data and I can't solve this question. I have data on pollinator abundance and fruit set from plant individuals (with different treatments - related to a pest infection -) sampled at six study sites (spatial replicas) and during two consecutive years (time replicas). The problem is that not all individuals (plants) were sampled in both years (because of lack of bloom). My question is: How should i use &quot;Year&quot;, as random effect or as fixed effect? I constructed three candidate models and compared the AIC: a) Response variable ~Predictor variables + (1 | year/plant) + (1 | site/plant) b) Response variable ~Predictor variables + (1 | year) + (1 | site/plant)  c) Response variable ~Predictor variables * year + (1 | site/plant) Option a) had the lowest AIC and the highest R2, but I read in some papers that is not correct use a variable with less than five levels as random effect ... so, anyone could help me? sci-fi book where a meteorite gives 3 different kinds of telepathic powers to people who then vie for control 3 groups of telepaths each with different powers.  They received their powers from a meteorite.  One group is the strongest and are kind of in control.  Another group wants to gain control.  One group, I believe the strongest, have telepathic battles to determine the strength of one another conjuring up swords, walls, etc. in their minds. It was written by a lawyer.  Could have been written in the ‘80s, or earlier. How do I make Bash my default shell on Ubuntu?