Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doesn't build #5

Open
yves-chevallier opened this issue Dec 4, 2023 · 0 comments
Open

Doesn't build #5

yves-chevallier opened this issue Dec 4, 2023 · 0 comments

Comments

@yves-chevallier
Copy link

Unfortunately it doesn't seem to build :(

$ git rev-parse master
81d098d9b51fb0bb383cecad0af2b6ece945f671
$ make
g++ -c -g Boid.cpp
g++ -c -g Flock.cpp
In file included from Flock.cpp:2:
Flock.h:22:11: error: ‘Boid& Flock::getBoid(int)’ cannot be overloaded with ‘Boid Flock::getBoid(int)’
   22 |     Boid &getBoid(int i);
      |           ^~~~~~~
Flock.h:21:10: note: previous declaration ‘Boid Flock::getBoid(int)’
   21 |     Boid getBoid(int i);
      |          ^~~~~~~
Flock.cpp:20:7: error: no declaration matches ‘Boid& Flock::getBoid(int)’
   20 | Boid &Flock::getBoid(int i)
      |       ^~~~~
Flock.cpp:14:6: note: candidate is: ‘Boid Flock::getBoid(int)’
   14 | Boid Flock::getBoid(int i)
      |      ^~~~~
In file included from Flock.cpp:2:
Flock.h:14:7: note: ‘class Flock’ defined here
   14 | class Flock {
      |       ^~~~~
make: *** [makefile:21: Flock.o] Error 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant