• Post Reply Bookmark Topic Watch Topic
  • New Topic

static variables memory  RSS feed

 
raghu nagabandi
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
where the memory is allocated for static variables and methods?
 
Mihai Fonoage
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Static variables are allocated in a fixed location in RAM called the "static storage" (not on the heap or on the stack).

Mihai
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!