Calvin reacted to TMZ's story -- that Taylor wrote the lyrics and recorded a demo of the song, which Calvin used to produce the final edit ... with Rihanna singing.
He started with a compliment, saying Taylor is an "Amazing lyric writer and she smashed it as usual." But then came his true feelings -- "I wrote the music, produced the song, arranged it and cut the vocals though. And initially she wanted it kept secret."
During the Twitter rant, he also said it was "hurtful" that Taylor and co. are trying to make him look bad -- and suggested she focus on her new relationship, instead of attacking him.
And then the coup de grace -- a reference to (and confirmation of) her most famous beef. Before him.
I know you're off tour and you need someone new to try and bury like Katy ETC but I'm not that guy, sorry. I won't allow it— Calvin Harris (@CalvinHarris) July 13, 2016
Somewhere Taylor Swift is writing a song.
12:00 PM PT -- Katy Perry just responded in epic fashion ... clearly showing where she stands on the situation.