[antlr-interest] unexpected end of subtree

Mr Torsten Curdt tcurdt at yahoo.com
Sun Jun 20 11:18:40 PDT 2004


Can someone please explain why the following
snippet generates an "unexpected end of subtree"
warning? Everything else seem to be fine.

keyvalue returns [ Object o ]
  {
    o = null;
    String kn;
    Object kv;
  }
  : { java.util.HashMap map = new java.util.HashMap();
o = map; }
    ( 
      #(KEY kn=literal kv=literal) {
        map.put(kn,kv);        
      }
    )+
  | #(VALUE kv=literal) {
      o = kv;
    }
  ;

Is it because (#KEY)+ is unbound? I assume
I get the warning when the end of the childs
are reached.

cheers
--
Torsten


	
		
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail 


 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
     http://groups.yahoo.com/group/antlr-interest/

<*> To unsubscribe from this group, send an email to:
     antlr-interest-unsubscribe at yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
     http://docs.yahoo.com/info/terms/
 



More information about the antlr-interest mailing list