B
bg_ie
Hi all,
I'm trying to use the following kit -
http://ccrma.stanford.edu/software/stk/
but I'm having trouble building the code. I've tried isolating the
problem by deleting code and removing files from the project and here's
what I was left with -
voicer1.h -
#ifndef STK_VOICER_H
#define STK_VOICER_H
#include <vector>
class Voicer
{
public:
struct Voice
{
Voice();
};
std::vector<Voice> voices_;
};
#endif
Voicer1.cpp -
#include "Voicer1.h"
// nothing else
These are the only files left in my project and when I compile
voicer1.cpp this is what I get -
Voicer1.cpp
C:\Program Files\DevStudio\VC\INCLUDE\vector(103) : error C2065:
'Voice' : undeclared identifier
C:\Program Files\DevStudio\VC\INCLUDE\vector(103) : error C2440:
'default argument' : cannot convert from 'int' to 'const struct
Voicer::Voice &'
Reason: cannot convert from 'int' to 'const struct Voicer::Voice'
No
constructor could take the source type, or constructor overload
resolution was ambiguous
Error executing cl.exe.
I'm using Microsoft Developer Studio 97. Can anyone tell me what the
problem is. The errors above isa the same ('Voice' : undeclared) as
those I got before I started deleting code from voicer1.cpp and
voicer.h.
Thanks for your help,
Barry.
I'm trying to use the following kit -
http://ccrma.stanford.edu/software/stk/
but I'm having trouble building the code. I've tried isolating the
problem by deleting code and removing files from the project and here's
what I was left with -
voicer1.h -
#ifndef STK_VOICER_H
#define STK_VOICER_H
#include <vector>
class Voicer
{
public:
struct Voice
{
Voice();
};
std::vector<Voice> voices_;
};
#endif
Voicer1.cpp -
#include "Voicer1.h"
// nothing else
These are the only files left in my project and when I compile
voicer1.cpp this is what I get -
Voicer1.cpp
C:\Program Files\DevStudio\VC\INCLUDE\vector(103) : error C2065:
'Voice' : undeclared identifier
C:\Program Files\DevStudio\VC\INCLUDE\vector(103) : error C2440:
'default argument' : cannot convert from 'int' to 'const struct
Voicer::Voice &'
Reason: cannot convert from 'int' to 'const struct Voicer::Voice'
No
constructor could take the source type, or constructor overload
resolution was ambiguous
Error executing cl.exe.
I'm using Microsoft Developer Studio 97. Can anyone tell me what the
problem is. The errors above isa the same ('Voice' : undeclared) as
those I got before I started deleting code from voicer1.cpp and
voicer.h.
Thanks for your help,
Barry.