Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

constructor  RSS feed

 
sano vasu
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hai Friends, please help me

why a constructor should not be prefixed with transient and volatile specifiers
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"ksvasu",
thanks you for changing your display name, but we require TWO words, your first name, then your last name. Plerase see the previous warning and try again.

Thanks,
Dave.
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24217
38
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by ksvasu:
Hai Friends, please help me

why a constructor should not be prefixed with transient and volatile specifiers


Because neither of these qualifiers can be used for any methods, not just constructors. They both apply only to member variables.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!