# operator=

One important part is the following syntax for an "operator="override:

`type& type :: operator=( [const | volatile] type& )`

Which means that for FunctList the "operator=" override needs to be declared something like:

`FunctList& operator=(FunctList &pf);`

Also be sure to use "this" in "operator=" overrides as shown in examples, unless you are sure it is not necessary. So your "operator=" override needs to have assignment statements in the following format:

`this->?=a.?;`

where "?" is a member variable that needs to be copied. Finally, the "operator=" override needs to return "*this" as in the following:

`return *this;`

So the following are samples of "operator=" functions. The first one is very basic:

```class CSimple {
virtual ~CSimple(){}
CSimple &operator=(const CSimple &Parameter) {
return *this;
};
};```

This other one has a CList collection member:

```class CWithList {
CWithList();
virtual ~CWithList();
CString m_Name;
CList <COperation,COperation&> m_SomeList;
CWithList &operator=(const CWithList &Parameter) {
{"ft_lang_label":"__label__en","ft_lang_prob":0.75951463,"math_prob":0.79775304,"size":1458,"snap":"2019-51-2020-05","text_gpt3_token_len":370,"char_repetition_ratio":0.14649244,"word_repetition_ratio":0.02116402,"special_character_ratio":0.24485597,"punctuation_ratio":0.19591837,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.96957326,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2020-01-29T03:00:56Z\",\"WARC-Record-ID\":\"<urn:uuid:e8c4e2eb-69c4-48f0-84c2-5f56b59508a8>\",\"Content-Length\":\"5361\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:e7bd4c51-aba3-430d-bb80-0027e7ab00dd>\",\"WARC-Concurrent-To\":\"<urn:uuid:35fed50f-cc6e-4c9d-937a-2e795be7a8fa>\",\"WARC-IP-Address\":\"64.209.142.239\",\"WARC-Target-URI\":\"http://simplesamples.info/CPluPlus/OperatorEqual.aspx\",\"WARC-Payload-Digest\":\"sha1:RC5QBHB3XUDANTH35MJNCYIX7CXON7DQ\",\"WARC-Block-Digest\":\"sha1:K3FTEU2CD3UHVSAAMPX6NW4LIASTLWAO\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2020/CC-MAIN-2020-05/CC-MAIN-2020-05_segments_1579251783621.89_warc_CC-MAIN-20200129010251-20200129040251-00494.warc.gz\"}"}