title: Understanding forward declaration warning
body: <p>I am writing my first lines in objective-c for an iPhone app.</p>
  
  <p>This is the code:</p>
  
  <pre><code>/* ViewController.h */
  @protocol ImageFlowScrollViewDelegate;
  
  @interface ViewController : UIViewController&lt;ImageFlowScrollViewDelegate&gt; {
      NSMutableArray *characters;
      UILabel *actorName;
  }
  
  /* ViewController.m */
  #import "ImageFlowScrollView.h"
  @implementation IMDBViewController
  /* methods here */
  
  /* ImageFlowScrollView.h */
  @protocol ImageFlowScrollViewDelegate;
  
  @interface ImageFlowScrollView : UIScrollView&lt;UIScrollViewDelegate&gt; {
  
      NSMutableArray *buttonsArray;
      id&lt;ImageFlowScrollViewDelegate&gt; imageFlowScrollViewDelegate;
  
  }
  
  @property(nonatomic, assign)id&lt;ImageFlowScrollViewDelegate&gt; imageFlowScrollViewDelegate;
  
  - (id)initWithFrame:(CGRect)frame imageArray:(NSArray *) anArray;
  - (void)focusImageAtIndex:(NSInteger) index;
  
  @end
  
  
  @protocol ImageFlowScrollViewDelegate&lt;NSObject&gt;
  
  @optional
  - (void)imageFlow:(ImageFlowScrollView *)sender didFocusObjectAtIndex: (NSInteger) index;
  - (void)imageFlow:(ImageFlowScrollView *)sender didSelectObjectAtIndex: (NSInteger) index;
  @end
  </code></pre>
  
  <p>Doing this, I get a </p>
  
  <blockquote>
    <p>warning: no definition of protocol
    'ImageFlowScrollViewDelegate' is found</p>
  </blockquote>
  
  <p>I can fix it using:</p>
  
  <pre><code>#import "ImageFlowScrollView.h"
  
  @interface IMDBViewController : UIViewController&lt;ImageFlowScrollViewDelegate&gt; {
      NSMutableArray *characters;
      UILabel *actorName;
  }
  </code></pre>
  
  <p>but I would like to know why the forward declaration approach is giving me a warning.</p>