# Strange warning from ACLiC (or Cling)?

**URL:** <https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266>\
**Category:** ROOT\
**Tags:** cling\
**Created:** [October 1, 2025, 10:12am UTC](https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266 "2025-10-01T10:12:57Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nick\_van\_Eijndhoven](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/nick_van_eijndhoven/32/37816_2.png) [@Nick\_van\_Eijndhoven](https://root-forum.cern.ch/u/Nick_van_Eijndhoven)\
**Post date:** [October 1, 2025, 10:12am UTC](https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266/1 "2025-10-01T10:12:57Z")

</div>

* * *

Hi,

In compiling my class NcAstrolab2.cxx within ROOT via ACLiC I get the following warning, which I didn’t see using gcc on the same system. I have attached the source files NcAstrolab2.h and NcAstrolab2.cxx as well as the ROOT macro test1.cc and the produced output file test1.txt (a renamed version of the original test1.log). Since gcc doesn’t issue such a warning, I guess that my code is standard C++ compliant and if so, how can I suppress this disturbing warning in ACliC, Or is it something I have to change in my code in view of newer compiler versions coming up ?

ncfs\>root -b -q -e ‘gROOT-\>LoadMacro(“NcAstrolab2.cxx+”);’ test1.cc \>test1.log  
Info in TUnixSystem::ACLiC: creating shared library /ada\_mnt/ada/user/nickve/test/NcGRB/alerts/./NcAstrolab2\_cxx.so  
In file included from /ada\_mnt/ada/user/nickve/test/NcGRB/alerts/NcAstrolab2\_cxx\_ACLiC\_dict.cxx:41:  
/ada\_mnt/ada/user/nickve/test/NcGRB/alerts/./NcAstrolab2.cxx: In copy constructor ‘NcAstrolab2::NcAstrolab2(const NcAstrolab2&)’:  
/ada\_mnt/ada/user/nickve/test/NcGRB/alerts/./NcAstrolab2.cxx:460:12: warning: implicitly-declared ‘NcPosition& NcPosition::operator=(const NcPosition&)’ is deprecated [-Wdeprecated-copy]  
460 | fLabPos=t.fLabPos;  
| ^ ~~~~~~  
In file included from /ada\_mnt/ada/user/nickve/test/NcGRB/alerts/./NcAstrolab2.h:36,  
from /ada\_mnt/ada/user/nickve/test/NcGRB/alerts/./NcAstrolab2.cxx:188,  
from /ada\_mnt/ada/user/nickve/test/NcGRB/alerts/NcAstrolab2\_cxx\_ACLiC\_dict.cxx:41:  
/ada\_mnt/ada/software/icecube/nick/ncfs/ncfspack/source/NcPosition.h:22:3: note: because ‘NcPosition’ has user-provided ‘NcPosition::NcPosition(const NcPosition&)’  
22 | NcPosition(const NcPosition& p); // Copy constructor  
| ^ ~~~~~~~~~

_Please read [tips for efficient and successful posting](https://root-forum.cern.ch/t/tips-for-efficient-and-successful-posting/28292) and [posting code](https://root-forum.cern.ch/t/posting-code-read-this-first/28293)_

_Please fill also the fields below. Note that **`root -b -q`** will tell you this info, and starting from 6.28/06 upwards, you can call **`.forum bug`** from the ROOT prompt to pre-populate a topic._

* * *

| Welcome to ROOT 6.34.02 [https://root.cern](https://root.cern) |  
| (c) 1995-2024, The ROOT Team; conception: R. Brun, F. Rademakers |  
| Built for linuxx8664gcc on Jan 31 2025, 23:21:21 |  
| From tags/6-34-02@6-34-02 |  
| With g++ (GCC) 11.3.0 |

| Try ‘.help’/‘.?’, ‘.demo’, ‘.license’, ‘.credits’, ‘.quit’/‘.q’ |
| --- |
| |

[NcAstrolab2.cxx](https://root-forum.cern.ch/uploads/short-url/ebrr6nf7Zfpe5XprdJVDNZEklC1.cxx) (645.2 KB)

[NcAstrolab2.h](https://root-forum.cern.ch/uploads/short-url/g3J5mcPnrO5AJnF8Klyh3Nzp1Dt.h) (36.0 KB)

[test1.cc](https://root-forum.cern.ch/uploads/short-url/fqIdH6BuIO4HSjZJqdxBynfwiT4.cc) (2.6 KB)

[test1.txt](https://root-forum.cern.ch/uploads/short-url/d5bw2k6eNkbrLc9ENHywZuzZvLZ.txt) (11.6 KB)

* * *

---

<div class="post-metadata">

**Author:** ![couet](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/couet/32/12037_2.png) [@couet](https://root-forum.cern.ch/u/couet)\
**Post date:** [October 1, 2025, 10:47am UTC](https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266/2 "2025-10-01T10:47:46Z")

</div>

I guess @pcanal or @devajith can help.

---

<div class="post-metadata">

**Author:** ![pcanal](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/pcanal/32/12439_2.png) [@pcanal](https://root-forum.cern.ch/u/pcanal)\
**Post date:** [October 1, 2025, 4:31pm UTC](https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266/3 "2025-10-01T16:31:00Z")

</div>

> [@Nick\_van\_Eijndhoven](#):
>
> NcPosition& NcPosition::operator=(const NcPosition&)

You need to implement this function. The warning says that since you implemented `NcPosition(const NcPosition& p); // Copy constructor`  
you probably also need to customize the assignment operator.

---

<div class="post-metadata">

**Author:** ![Nick\_van\_Eijndhoven](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/nick_van_eijndhoven/32/37816_2.png) [@Nick\_van\_Eijndhoven](https://root-forum.cern.ch/u/Nick_van_Eijndhoven)\
**Post date:** [October 2, 2025, 7:50am UTC](https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266/4 "2025-10-02T07:50:54Z")

</div>

Hi Philippe,

Thanks for the clarification; that makes sense 😉 However, as it is now, it just works. When I get some time I will implement it in order to get rid of the warnings.

Cheers,

Nick.

---

<div class="post-metadata">

**Author:** ![system](https://root-forum.cern.ch/uploads/default/original/3X/e/f/efe4f24398fd8ffeb76bccb6ecc46d9d9c003376.png) [@system](https://root-forum.cern.ch/u/system)\
**Post date:** [October 16, 2025, 7:51am UTC](https://root-forum.cern.ch/t/strange-warning-from-aclic-or-cling/64266/5 "2025-10-16T07:51:51Z")

</div>

Closed on October 16, 2025, 7:51am UTC

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
