There's a sense of irony at play in "The Nightingale and the Rose" that subverts the expectations of the fairy tale genre, thus providing a social commentary on the rationalist age in which Wilde lived.
The Student's devotion to intellectualism and rationality ultimately proves ironic, since he turns out to be one of the most foolish and irrational characters in the text. Wilde highlights this through the use of dramatic irony. When the Nightingale tells the Student about the sacrifice she is going to make in order to secure him his desired red rose, the Student is unable to understand her. Responding to her song, he says:
"She has form, [...] that cannot be denied to her; but has she got feeling? I am afraid not. In fact, she is like most artists; she is all style, without any sincerity. She would not sacrifice herself for others. She thinks merely of music, and everybody knows that the arts are selfish."
Wilde uses dramatic irony in this moment, as it has already been made clear that the Nightingale is the most selfless character in this story. And yet, the Student suggests that she's "selfish." Immediately after this speech, the Nightingale flies to the tree and sacrifices herself for the Student's love. The claim that "she would not sacrifice herself for others" thus spotlights the Student's ignorance.
Once the Nightingale has sacrificed herself to create the red rose, the Student looks out his window and says:
"Why, what a wonderful piece of luck!" he cried; "here is a red rose! I have never seen any rose like it in all my life. It is so beautiful that I am sure it has a long Latin name"; and he leaned down and plucked it.
The contrast between the vivid passage that precedes this (in which the Nightingale presses her breast against the thorn and gives her blood to stain the rose) and the Student's exclamation of "luck" is intentionally stark, again highlighting his ignorance. That the Student praises the rose's beauty by saying it must "have a long Latin name" emphasizes the irony of his supposedly educated worldview, which he uses to translate beauty into legible knowledge.
What's more, the irony of the entire situation becomes even more apparent when the Student later dismisses love as a "silly thing" with no practical use, returning to his "great dusty book"—the dustiness of which suggests that, for all his pretentious beliefs that intellectual pursuits are inherently worthwhile and practical, the books to which he has devoted his time are actually obscure and removed from the workings of everyday life. The irony, then, is that he criticizes love as an impractical thing, only to then devote himself to something that is even more useless and arbitrary than human emotion.