I left my program open for 9 hours and it used up 700mb of ram, could someone review it?
bearophile via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue Jan 27 07:45:46 PST 2015
Gan:
> How can I make it use less CPU/RAM?
Most tiny classes probably should be structs. More generally, use
a struct every time you don't need a class.
You can start with those two:
struct SBRange {
double left = 0.0, right = 0.0, top = 0.0, bottom = 0.0;
}
struct Point(T) {
T x, y;
}
This probably isn't enough to solve your problems, but it's a
start.
Bye,
bearophile
More information about the Digitalmars-d-learn
mailing list