Chiasmus is the repetition of any group of verse elements (including rhyme and grammatical structure) in reverse order, such as the rhyme scheme ABBA. Examples can be found in Biblical scripture. For instance, Matthew 19:30 reads
“But many that are first / Shall be last, / And many that are last / Shall be first.”
John Keats uses chiasmus in the last two lines of his “Ode on a Grecian Urn”
excerpt from Ode on a Grecian Urn by John Keats
"Beauty is truth, truth beauty,—that is all
Ye know on earth, and all ye need to know."