tools/clang/lib/Parse/ParseHLSL.cpp
/// ParseHLSLAttributes - Parse an HLSL attribute-specifier-seq.
///
/// attribute-specifier-seq:
///       attribute-specifier-seq[opt] attribute-specifier
Parse an HLSL attribute-specifier-seq.
Parse an HLSL attribute - specifier - seq .
void Parser::ParseHLSLAttributes(ParsedAttributesWithRange &attrs,
                                 SourceLocation *endLoc) {
  assert(getLangOpts().HLSL);
  SourceLocation StartLoc = Tok.getLocation(), Loc;
  if (!endLoc)
    endLoc = &Loc;
  do {
    ParseHLSLAttributeSpecifier(attrs, endLoc);
  } while (Tok.is(tok::l_square));
  attrs.Range = SourceRange(StartLoc, *endLoc);
}
void Parser :: ParseHLSLAttributes ( ParsedAttributesWithRange & attrs , SourceLocation * endLoc ) { assert ( getLangOpts ( ) . HLSL ) ; SourceLocation StartLoc = Tok . getLocation ( ) , Loc ; if ( ! endLoc ) endLoc = & Loc ; do { ParseHLSLAttributeSpecifier ( attrs , endLoc ) ; } while ( Tok . is ( tok :: l_square ) ) ; attrs . Range = SourceRange ( StartLoc , * endLoc ) ; }
ParseHLSLAttributes - Parse an HLSL attribute-specifier-seq.
ParseHLSLAttributes - Parse an HLSL attribute - specifier - seq .