KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I would like to learn what the robust way of checking, if a variable is of type string or gstring, is. I suppose it is different than in pure Java: def var = someFunc(); if (var instanceof String || var instanceof GString) { String str = var; } I ask, because I do not want to be surprised that I have missed a Groovy specific feature that causes a hard to debug bug.
Tags (comma-separated)
Save Edits
Cancel