title: objective-c runtime error "Use of undeclared identifier 'objc_property_t'"
body: <p>I'm trying to get the properties from my class using obj-c runtime approach I found on the answers from here, however I'm getting a lot of warnings/error when coding, do I need to import the library or make something in order to have the obj-c runtime functions available?</p>
  
  <p>objc_property_t *properties = class_copyPropertyList([self class], &amp;outCount);</p>
  
  <p>Warning: "Implicit declaration of function 'class_copyPropertyList' is invalid in C99
  Error: Use of undeclared identifier 'objc_property_t'</p>
  
  <p>This is the whole chunk that I've copied:</p>
  
  <pre><code>unsigned int outCount, i;
  objc_property_t *properties = class_copyPropertyList([self class], &amp;outCount);
  for (i = 0; i &lt; outCount; i++) {
      objc_property_t property = properties[i];
      NSString *propertyName = [[NSString alloc] initWithCString:property_getName(property)];
      id propertyValue = [self valueForKey:(NSString *)propertyName];
      if (propertyValue) [props setObject:propertyValue forKey:propertyName];
  }
  free(properties);
  </code></pre>
  
  <p>Thanks in advance!.</p>