<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def set_comment(self, obj, cursor):
 """ If a comment is available, add it to the typedesc."""

        if isinstance(obj, typedesc.T):
            obj.comment = cursor.brief_comment
        return