-
Notifications
You must be signed in to change notification settings - Fork 12
ObsoleteCommentSyntaxInspection
Inspection: ObsoleteCommentSyntaxInspection
Description: Use of obsolete Rem comment syntax
Type: CodeInspectionType.LanguageOpportunities
Default severity: CodeInspectionSeverity.Suggestion
This inspection finds comments that are marked by a Rem
instruction.
###Example:
Parameter foo
is implicitly passed ByRef
in this method signature:
Dim foo As Integer : Rem this is a comment
Rem this is a comment
The Rem
instruction exists in VBA only for backward compatibility reasons. New code should use a single quote ('
) to denote comments.
###QuickFixes
QuickFix: Replace 'Rem' usage with a single-quote comment marker
Dim foo As Integer ' this is a comment
' this is a comment
This quickfix replaces Rem
by a single quote character. It also removes the would-now-be superfluous instruction separator token (:
) that precedes a Rem
comment that would be following an instruction on the same line of code.