Article View: es.comp.os.linux.programacion
Article #12039Problemas con const
From: Salva
Date: Wed, 12 Sep 2001 17:38
Date: Wed, 12 Sep 2001 17:38
31 lines
1701 bytes
1701 bytes
Hola Tengo un problema con un constructor de una clase( C++). La clase tiene varios datos miembro, entre ellas tres arrays. La linea de c�digo del constructor es: Cara(const Cara& par); //Constructor El problema consiste en que para esos tres arrays me da los siguientes errores a compilar: cara.cpp: In method `Cara::Cara(const Cara &)': cara.cpp:51: incompatible types in assignment of `const double[15]' to `double[15]' cara.cpp:61: incompatible types in assignment of `const complex<float>[15]' to `complex<float>[15]' cara.cpp:62: incompatible types in assignment of `const complex<float>[15]' to `complex<float>[15]' �Es correcto colocar el const en el constructor? �Y si es as� porque me da este tipo de error? Gracias ; ADEU Salva salause@teleco.upv.es
Technical Details
Message-ID:
<9no6h0$bbl$1@polaris.cc.upv.es>Path:
arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!cpk-news-hub1.bbnplanet.com!news.gtei.net!newsfeed1.cidera.com!Cidera!news.comunitel.net!news.rediris.es!news.uv.es!news.upv.es!kabutShow Full Headers
Complete Article Headers
X-Google-Language: SPANISH,ASCII X-Google-Thread: f86c8,a883464b9398e6ed,start X-Google-Attributes: gidf86c8,public X-Google-ArrivalTime: 2001-09-12 10:47:54 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!cpk-news-hub1.bbnplanet.com!news.gtei.net!newsfeed1.cidera.com!Cidera!news.comunitel.net!news.rediris.es!news.uv.es!news.upv.es!kabut From: salause@teleco.upv.es (Salva) Newsgroups: es.comp.os.linux.programacion Subject: Problemas con const Date: Wed, 12 Sep 2001 17:38:49 GMT Organization: U.P.V. Lines: 31 Message-ID: <9no6h0$bbl$1@polaris.cc.upv.es> NNTP-Posting-Host: ext-a38.ras.upv.es X-Trace: polaris.cc.upv.es 1000316256 11637 158.42.240.38 (12 Sep 2001 17:37:36 GMT) X-Complaints-To: newsmaster@upv.es NNTP-Posting-Date: 12 Sep 2001 17:37:36 GMT X-Newsreader: News Xpress 2.01