[cfe-commits] r83092 - in /cfe/trunk: include/clang/Parse/DeclSpec.h lib/Parse/DeclSpec.cpp
Argiris Kirtzidis
akyrtzi at gmail.com
Tue Sep 29 12:42:11 PDT 2009
Author: akirtzidis
Date: Tue Sep 29 14:42:11 2009
New Revision: 83092
URL: http://llvm.org/viewvc/llvm-project?rev=83092&view=rev
Log:
Move DeclSpec::setProtocolQualifiers() out of line.
Modified:
cfe/trunk/include/clang/Parse/DeclSpec.h
cfe/trunk/lib/Parse/DeclSpec.cpp
Modified: cfe/trunk/include/clang/Parse/DeclSpec.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Parse/DeclSpec.h?rev=83092&r1=83091&r2=83092&view=diff
==============================================================================
--- cfe/trunk/include/clang/Parse/DeclSpec.h (original)
+++ cfe/trunk/include/clang/Parse/DeclSpec.h Tue Sep 29 14:42:11 2009
@@ -350,15 +350,7 @@
SourceLocation getProtocolLAngleLoc() const { return ProtocolLAngleLoc; }
void setProtocolQualifiers(const ActionBase::DeclPtrTy *Protos, unsigned NP,
SourceLocation *ProtoLocs,
- SourceLocation LAngleLoc) {
- if (NP == 0) return;
- ProtocolQualifiers = new ActionBase::DeclPtrTy[NP];
- ProtocolLocs = new SourceLocation[NP];
- memcpy((void*)ProtocolQualifiers, Protos, sizeof(ActionBase::DeclPtrTy)*NP);
- memcpy(ProtocolLocs, ProtoLocs, sizeof(SourceLocation)*NP);
- NumProtocolQualifiers = NP;
- ProtocolLAngleLoc = LAngleLoc;
- }
+ SourceLocation LAngleLoc);
/// Finish - This does final analysis of the declspec, issuing diagnostics for
/// things like "_Imaginary" (lacking an FP type). After calling this method,
Modified: cfe/trunk/lib/Parse/DeclSpec.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/DeclSpec.cpp?rev=83092&r1=83091&r2=83092&view=diff
==============================================================================
--- cfe/trunk/lib/Parse/DeclSpec.cpp (original)
+++ cfe/trunk/lib/Parse/DeclSpec.cpp Tue Sep 29 14:42:11 2009
@@ -334,6 +334,19 @@
return false;
}
+void DeclSpec::setProtocolQualifiers(const ActionBase::DeclPtrTy *Protos,
+ unsigned NP,
+ SourceLocation *ProtoLocs,
+ SourceLocation LAngleLoc) {
+ if (NP == 0) return;
+ ProtocolQualifiers = new ActionBase::DeclPtrTy[NP];
+ ProtocolLocs = new SourceLocation[NP];
+ memcpy((void*)ProtocolQualifiers, Protos, sizeof(ActionBase::DeclPtrTy)*NP);
+ memcpy(ProtocolLocs, ProtoLocs, sizeof(SourceLocation)*NP);
+ NumProtocolQualifiers = NP;
+ ProtocolLAngleLoc = LAngleLoc;
+}
+
/// Finish - This does final analysis of the declspec, rejecting things like
/// "_Imaginary" (lacking an FP type). This returns a diagnostic to issue or
/// diag::NUM_DIAGNOSTICS if there is no error. After calling this method,
More information about the cfe-commits
mailing list