While chatting, my phone rang suddenly.
In the sentence, the subject of the participle clause is different from that of the main clause. I'd like to know whether it is grammatical.
English Language Learners Stack Exchange is a question and answer site for speakers of other languages learning English. It only takes a minute to sign up.Sign up to join this community
Typically, the subject should be the same in both the main and participle phrase (clause), otherwise your sentence might suggest that your phone was chatting.
However, considering that the phones don't chat the sentence is pretty fine, even if it doesn't follow strict grammar rules.