Clavis Libri

Literary device

Foreshadowing

A sign, statement or image that anticipates, sometimes only for those who reread, something that will happen later in the work.

In Hamlet

Something is rotten in the state of Denmark.

Marcellus speaks before any revelation, and the line foreshadows the crime that the Ghost will tell about in the next scene. Whoever rereads hears in it the warning that evil is close to the throne.

Act I: The Ghost and the order of revenge, Marcellus