I've narrowed down my issues to a manageable point now. I've learned a huge lesson from all of this: always check your copypastas between files. Thanks to everyone who helped out.
P.S. laserlight,...
Type: Posts; User: William Putnam
I've narrowed down my issues to a manageable point now. I've learned a huge lesson from all of this: always check your copypastas between files. Thanks to everyone who helped out.
P.S. laserlight,...
Thanks, Jim, for pointing that out. I've fixed the code as per your suggestions, and added inodeNum to fileData (forgot to do this earlier). I am now down to one error:
Williams-iMac:wputn1_P3...
That was from oogabooga's earlier suggestions. My first post indicates what I was getting before I started.
Williams-iMac:wputn1_P3 Desktop$ c++ -o trippy -Wall -std=c++11 *.cpp
dirData.cpp:9:13: error: expected unqualified-id
fileData.statNode = s.getInode();
^
dirData.cpp:10:13:...
I'm usually not too cool with posting my code online because I fear that someone could take the whole thing and try to pass it as their own. But at this point, I'm going to have to take a risk on it....
Nope. Not working.
(At this point I should mention I'm running OSX ML 10.8.5 and Xcode v.5.0 with command line tools extension.)
It wouldn't take the -std argument. "Unrecognized."
oogabooga, your code did not compile on my computer, either for c++ or g++. g++ gave me these errors in the terminal:
d.cpp: In function ‘int main()’:
d.cpp:25: error: scalar object ‘v’...
No, I'm defining this as an inline in the header.
I tried adjusting it again, and as I feared, I started getting unrelated error messages from the constructor.
I gave it a shot, but it still gives one error, although shorter:
./fileData.hpp:20:27: error: extra qualification on member 'operator<'
bool inline fileData::operator<(const fileData& f)...
I'm currently working on a homework assignment where I have a vector of custom class objects. I want to sort these vector entries in alphabetical order. I've tried using my instructor's method of...