Item getItemWithFollowRestrictions(Item i, FollowRestrictions f) {		
				if (i instanceof EndItem) {
					return newEndItem;
				}
				
				if (i instanceof StartItem) {
					return newStartItem;
				}
				
				if ((reversed ? i.atEnd() : i.atBegin()) && i.production.reject) {
					f = null; // do not propagate into reject parts
				}
				
				Pair<Item, FollowRestrictions> p = new Pair<Item, FollowRestrictions>(i, f);
				Item j = followProp.get(p);
				if (j == null) {
					try{
						j = (Item) i.clone();
					} catch (CloneNotSupportedException e) {}
					
					j.unfoldedFrom = i;
					j.followRestrictions = f;
					j.withFollow = true;
					
					followProp.put(p, j);
					followPropTodo.add(j);
					newItems.add(j);
				}
				return j;
			}