add sentinel pattern define