rename rule to decl fix issue #6
refactoring
update tests