Вот простой тестовый код, иллюстрирующий некоторые странности, которые я обнаружил при использовании Sun CC: >
Код: Выделить всё
//---------------main.cpp
#include "wtc.hpp"
int main(int, char**)
{
testy t;
t.lame(99);
return 0;
}
//--------------wtc.hpp
#ifndef WTC_HPP_INCLUDED
#define WTC_HPP_INCLUDED
class testy
{
public:
void lame(int );
};
#endif
//---------------wtc.cpp
#include
#include "wtc.hpp"
void testy::lame(const int a)
{
std::cout
Подробнее здесь: [url]https://stackoverflow.com/questions/768588/is-the-const-value-parameter-in-definition-but-not-declaration-really-c[/url]