What do call it when they use modern music in period films for ironic juxtaposition/ecstatic truth?

I find it interesting when directors do this in films - use modern music in decidedly “period” films to create a sort of analogue to modern audiences about the period INSTEAD of going with period-appropriate music. That sounded dumbly academic - let me give examples.

Moulin Rouge is this principle in action as an entire film - the whole idea is that songs like “Material Girl” and “Smells like Teen Spirit” blaring as house music remixes capture the feeling that people of the era would have had going to the Moulin Rogue and hearing salacious can-can music more accurately/appropriately for a modern audience than actual period-appropriate music would have.

Kind of how it’s impossible for a modern audience to viscerally understand how the premiere of The Rite of Spring was so shocking that it caused a riot - we hear polite classical musical like we might have encountered on an elementary school trip to the local symphony. To recreate the true feeling of that event for a modern audience (if you were making a film of it), you’d have to do something like use crazy death metal music to capture the same feeling.

I’m thinking of this because I thought that Inglourious Basterds did the same thing to great effect throughout, even though it’s a WWII-era film. Using Bowie’s german-period music, for example, or the big electric guitar chord when a certain character is introduced.

What do you call this ironic juxtaposition?

Not sure if there’s a more specific term for music, but IIRC the soundtrack of A Knight’s Tale was always described simply as “anachronistic.”

Yeah, if it’s done effectively, then it’s “postmodern”. If it’s done lazily and unintelligently, then it’s “anachronistic”.