.

Discussion in 'Programming' started by Phaze, Jan 18, 2020.

Thread Status:
Not open for further replies.
  1. If I do
    Code (Text):
    new MyClass();
    for each user every time they log in, will this stay in memory although I am not assigning a variable to it?
     
    • Winner Winner x 1
  2. Since you’re not referencing it I do believe it would be cleaned up by the GC but why would you want to do that? If you’re adding the class to a manager when you call the constructor or something like that, since you’re adding a reference there then it wouldn’t be cleaned up.
     
Thread Status:
Not open for further replies.