Loading ...
Sorry, an error occurred while loading the content.

1976Re: option.forin

Expand Messages
  • Douglas Crockford
    Feb 24, 2011
    • 0 Attachment
      --- In jslint_com@yahoogroups.com, "bluflonalgul" <bluflonalgul@...> wrote:

      > I think there is this case where the 'for in' loops on a object used as a record.
      > Does it makes sense here to had such tests mentioned in your option.forin ?


      Yes, because some third party code could insert something into Object.prototype without your knowledge and approval. So program defensively, so that your code will always perform correctly.
    • Show all 8 messages in this topic