2014-03-06 15:29:08 +02:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
|
|
/*
|
|
|
|
* This file is part of the LibreOffice project.
|
|
|
|
*
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <string>
|
2014-05-19 10:02:29 +02:00
|
|
|
#include <set>
|
2014-03-06 15:29:08 +02:00
|
|
|
|
2016-06-28 18:54:31 +02:00
|
|
|
#include "check.hxx"
|
2016-04-13 08:27:17 +02:00
|
|
|
#include "compat.hxx"
|
2016-06-28 18:54:31 +02:00
|
|
|
#include "plugin.hxx"
|
2014-03-06 15:29:08 +02:00
|
|
|
|
2014-05-16 11:18:12 +02:00
|
|
|
// Find places where various things are passed by value.
|
2014-03-06 15:29:08 +02:00
|
|
|
// It's not very efficient, because we generally end up copying it twice - once into the parameter and
|
2014-05-16 11:18:12 +02:00
|
|
|
// again into the destination.
|
2014-03-06 15:29:08 +02:00
|
|
|
// They should rather be passed by reference.
|
2015-02-05 16:53:30 +01:00
|
|
|
//
|
|
|
|
// Generally recommending lambda capture by-ref rather than by-copy is even more
|
|
|
|
// problematic than with function parameters, as a lambda instance can easily
|
|
|
|
// outlive a referrenced variable. So once lambdas start to get used in more
|
|
|
|
// sophisticated ways than passing them into standard algorithms, this plugin's
|
|
|
|
// advice, at least for explicit captures, will need to be revisited.
|
2014-03-06 15:29:08 +02:00
|
|
|
|
|
|
|
namespace {
|
|
|
|
|
2014-05-16 11:18:12 +02:00
|
|
|
class PassStuffByRef:
|
|
|
|
public RecursiveASTVisitor<PassStuffByRef>, public loplugin::Plugin
|
2014-03-06 15:29:08 +02:00
|
|
|
{
|
|
|
|
public:
|
2016-04-26 15:50:12 +02:00
|
|
|
explicit PassStuffByRef(InstantiationData const & data): Plugin(data), mbInsideFunctionDecl(false), mbFoundDisqualifier(false) {}
|
2014-03-06 15:29:08 +02:00
|
|
|
|
|
|
|
virtual void run() override { TraverseDecl(compiler.getASTContext().getTranslationUnitDecl()); }
|
|
|
|
|
2016-06-13 19:22:12 +02:00
|
|
|
// When warning about function params of primitive type that could be passed
|
|
|
|
// by value instead of by reference, make sure not to warn if the paremeter
|
|
|
|
// is ever bound to a reference; on the one hand, this needs scaffolding in
|
|
|
|
// all Traverse*Decl functions (indirectly) derived from FunctionDecl; and
|
|
|
|
// on the other hand, use a hack of ignoring just the DeclRefExprs nested in
|
|
|
|
// LValueToRValue ImplicitCastExprs when determining whether a param is
|
|
|
|
// bound to a reference:
|
|
|
|
bool TraverseFunctionDecl(FunctionDecl * decl);
|
|
|
|
bool TraverseCXXMethodDecl(CXXMethodDecl * decl);
|
|
|
|
bool TraverseCXXConstructorDecl(CXXConstructorDecl * decl);
|
|
|
|
bool TraverseCXXDestructorDecl(CXXDestructorDecl * decl);
|
|
|
|
bool TraverseCXXConversionDecl(CXXConversionDecl * decl);
|
2014-03-06 15:29:08 +02:00
|
|
|
bool VisitFunctionDecl(const FunctionDecl * decl);
|
2016-06-13 19:22:12 +02:00
|
|
|
bool TraverseImplicitCastExpr(ImplicitCastExpr * expr);
|
|
|
|
bool VisitDeclRefExpr(const DeclRefExpr * expr);
|
|
|
|
|
2016-04-13 08:27:17 +02:00
|
|
|
bool VisitCallExpr(const CallExpr * ) { if (mbInsideFunctionDecl) mbFoundDisqualifier = true; return true; }
|
|
|
|
bool VisitMaterializeTemporaryExpr(const MaterializeTemporaryExpr * ) { if (mbInsideFunctionDecl) mbFoundDisqualifier = true; return true; }
|
|
|
|
bool VisitDeclStmt(const DeclStmt * ) { if (mbInsideFunctionDecl) mbFoundDisqualifier = true; return true; }
|
2015-02-05 16:53:30 +01:00
|
|
|
bool VisitLambdaExpr(const LambdaExpr * expr);
|
|
|
|
|
|
|
|
private:
|
2016-06-13 19:22:12 +02:00
|
|
|
template<typename T> bool traverseAnyFunctionDecl(
|
2016-06-14 08:42:42 +02:00
|
|
|
T * decl, bool (RecursiveASTVisitor::* fn)(T *));
|
2016-05-05 09:46:12 +02:00
|
|
|
void checkParams(const FunctionDecl * functionDecl);
|
|
|
|
void checkReturnValue(const FunctionDecl * functionDecl, const CXXMethodDecl * methodDecl);
|
2015-12-08 22:56:02 +01:00
|
|
|
bool isFat(QualType type);
|
2016-05-05 09:46:12 +02:00
|
|
|
bool isPrimitiveConstRef(QualType type);
|
2016-04-13 08:27:17 +02:00
|
|
|
bool mbInsideFunctionDecl;
|
|
|
|
bool mbFoundDisqualifier;
|
2016-06-13 19:22:12 +02:00
|
|
|
|
|
|
|
struct FDecl {
|
|
|
|
std::set<ParmVarDecl const *> parms;
|
|
|
|
bool check = false;
|
|
|
|
};
|
|
|
|
std::vector<FDecl> functionDecls_;
|
2014-03-06 15:29:08 +02:00
|
|
|
};
|
|
|
|
|
2016-05-05 09:46:12 +02:00
|
|
|
bool startswith(const std::string& rStr, const char* pSubStr) {
|
|
|
|
return rStr.compare(0, strlen(pSubStr), pSubStr) == 0;
|
|
|
|
}
|
|
|
|
|
2016-06-13 19:22:12 +02:00
|
|
|
bool PassStuffByRef::TraverseFunctionDecl(FunctionDecl * decl) {
|
|
|
|
return traverseAnyFunctionDecl(
|
|
|
|
decl, &RecursiveASTVisitor::TraverseFunctionDecl);
|
|
|
|
}
|
|
|
|
|
|
|
|
bool PassStuffByRef::TraverseCXXMethodDecl(CXXMethodDecl * decl) {
|
|
|
|
return traverseAnyFunctionDecl(
|
|
|
|
decl, &RecursiveASTVisitor::TraverseCXXMethodDecl);
|
|
|
|
}
|
|
|
|
|
|
|
|
bool PassStuffByRef::TraverseCXXConstructorDecl(CXXConstructorDecl * decl) {
|
|
|
|
return traverseAnyFunctionDecl(
|
|
|
|
decl, &RecursiveASTVisitor::TraverseCXXConstructorDecl);
|
|
|
|
}
|
|
|
|
|
|
|
|
bool PassStuffByRef::TraverseCXXDestructorDecl(CXXDestructorDecl * decl) {
|
|
|
|
return traverseAnyFunctionDecl(
|
|
|
|
decl, &RecursiveASTVisitor::TraverseCXXDestructorDecl);
|
|
|
|
}
|
|
|
|
|
|
|
|
bool PassStuffByRef::TraverseCXXConversionDecl(CXXConversionDecl * decl) {
|
|
|
|
return traverseAnyFunctionDecl(
|
|
|
|
decl, &RecursiveASTVisitor::TraverseCXXConversionDecl);
|
|
|
|
}
|
|
|
|
|
|
|
|
template<typename T> bool PassStuffByRef::traverseAnyFunctionDecl(
|
2016-06-14 08:42:42 +02:00
|
|
|
T * decl, bool (RecursiveASTVisitor::* fn)(T *))
|
2016-06-13 19:22:12 +02:00
|
|
|
{
|
|
|
|
if (ignoreLocation(decl)) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
if (decl->doesThisDeclarationHaveABody()) {
|
|
|
|
functionDecls_.emplace_back();
|
|
|
|
}
|
|
|
|
bool ret = (this->*fn)(decl);
|
|
|
|
if (decl->doesThisDeclarationHaveABody()) {
|
|
|
|
assert(!functionDecls_.empty());
|
|
|
|
if (functionDecls_.back().check) {
|
|
|
|
for (auto d: functionDecls_.back().parms) {
|
|
|
|
report(
|
|
|
|
DiagnosticsEngine::Warning,
|
|
|
|
("passing primitive type param %0 by const &, rather pass"
|
|
|
|
" by value"),
|
|
|
|
d->getLocation())
|
|
|
|
<< d->getType() << d->getSourceRange();
|
|
|
|
auto can = decl->getCanonicalDecl();
|
|
|
|
if (can->getLocation() != decl->getLocation()) {
|
|
|
|
report(
|
|
|
|
DiagnosticsEngine::Note, "function is declared here:",
|
|
|
|
can->getLocation())
|
|
|
|
<< can->getSourceRange();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
functionDecls_.pop_back();
|
|
|
|
}
|
|
|
|
return ret;
|
|
|
|
}
|
|
|
|
|
2014-05-16 11:18:12 +02:00
|
|
|
bool PassStuffByRef::VisitFunctionDecl(const FunctionDecl * functionDecl) {
|
2014-03-06 15:29:08 +02:00
|
|
|
if (ignoreLocation(functionDecl)) {
|
|
|
|
return true;
|
|
|
|
}
|
2016-06-08 17:14:34 +02:00
|
|
|
if (functionDecl->isDeleted()
|
|
|
|
|| functionDecl->isFunctionTemplateSpecialization())
|
|
|
|
{
|
2014-03-06 15:29:08 +02:00
|
|
|
return true;
|
2016-06-08 17:14:34 +02:00
|
|
|
}
|
2014-05-21 08:32:01 +02:00
|
|
|
// only consider base declarations, not overriden ones, or we warn on methods that
|
|
|
|
// are overriding stuff from external libraries
|
2016-04-13 08:27:17 +02:00
|
|
|
const CXXMethodDecl * methodDecl = dyn_cast<CXXMethodDecl>(functionDecl);
|
|
|
|
if (methodDecl && methodDecl->size_overridden_methods() > 0) {
|
2014-05-21 08:32:01 +02:00
|
|
|
return true;
|
|
|
|
}
|
2016-05-05 09:46:12 +02:00
|
|
|
|
|
|
|
checkParams(functionDecl);
|
|
|
|
checkReturnValue(functionDecl, methodDecl);
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2016-06-13 19:22:12 +02:00
|
|
|
bool PassStuffByRef::TraverseImplicitCastExpr(ImplicitCastExpr * expr) {
|
|
|
|
if (ignoreLocation(expr)) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return
|
|
|
|
(expr->getCastKind() == CK_LValueToRValue
|
|
|
|
&& (dyn_cast<DeclRefExpr>(expr->getSubExpr()->IgnoreParenImpCasts())
|
|
|
|
!= nullptr))
|
|
|
|
|| RecursiveASTVisitor::TraverseImplicitCastExpr(expr);
|
|
|
|
}
|
|
|
|
|
|
|
|
bool PassStuffByRef::VisitDeclRefExpr(const DeclRefExpr * expr) {
|
|
|
|
if (ignoreLocation(expr)) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
auto d = dyn_cast<ParmVarDecl>(expr->getDecl());
|
|
|
|
if (d == nullptr) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
for (auto & fd: functionDecls_) {
|
|
|
|
if (fd.parms.erase(d) == 1) {
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2016-05-05 09:46:12 +02:00
|
|
|
void PassStuffByRef::checkParams(const FunctionDecl * functionDecl) {
|
2016-06-08 17:14:34 +02:00
|
|
|
// Only warn on the definition of the function:
|
2016-06-13 19:22:12 +02:00
|
|
|
if (!functionDecl->doesThisDeclarationHaveABody()) {
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
unsigned n = functionDecl->getNumParams();
|
|
|
|
for (unsigned i = 0; i != n; ++i) {
|
|
|
|
const ParmVarDecl * pvDecl = functionDecl->getParamDecl(i);
|
|
|
|
auto const t = pvDecl->getType();
|
|
|
|
if (isFat(t)) {
|
|
|
|
report(
|
|
|
|
DiagnosticsEngine::Warning,
|
|
|
|
("passing %0 by value, rather pass by const lvalue reference"),
|
|
|
|
pvDecl->getLocation())
|
|
|
|
<< t << pvDecl->getSourceRange();
|
2014-05-16 11:18:12 +02:00
|
|
|
}
|
2016-04-13 08:27:17 +02:00
|
|
|
}
|
2016-05-05 09:46:12 +02:00
|
|
|
// ignore stuff that forms part of the stable URE interface
|
|
|
|
if (isInUnoIncludeFile(compiler.getSourceManager().getSpellingLoc(
|
|
|
|
functionDecl->getCanonicalDecl()->getNameInfo().getLoc()))) {
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
// these functions are passed as parameters to another function
|
|
|
|
std::string aFunctionName = functionDecl->getQualifiedNameAsString();
|
|
|
|
if (startswith(aFunctionName, "slideshow::internal::ShapeAttributeLayer")) {
|
|
|
|
return;
|
|
|
|
}
|
2016-06-13 19:22:12 +02:00
|
|
|
assert(!functionDecls_.empty());
|
|
|
|
functionDecls_.back().check = true;
|
2016-05-05 09:46:12 +02:00
|
|
|
for (unsigned i = 0; i != n; ++i) {
|
|
|
|
const ParmVarDecl * pvDecl = functionDecl->getParamDecl(i);
|
|
|
|
auto const t = pvDecl->getType();
|
|
|
|
if (isPrimitiveConstRef(t)) {
|
2016-06-13 19:22:12 +02:00
|
|
|
functionDecls_.back().parms.insert(pvDecl);
|
2016-05-05 09:46:12 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2016-04-13 08:27:17 +02:00
|
|
|
|
2016-05-05 09:46:12 +02:00
|
|
|
void PassStuffByRef::checkReturnValue(const FunctionDecl * functionDecl, const CXXMethodDecl * methodDecl) {
|
2016-04-13 08:27:17 +02:00
|
|
|
|
|
|
|
if (methodDecl && methodDecl->isVirtual()) {
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
}
|
|
|
|
if( !functionDecl->hasBody()) {
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
}
|
|
|
|
|
2016-06-28 16:25:55 +02:00
|
|
|
const QualType type = compat::getReturnType(*functionDecl).getDesugaredType(compiler.getASTContext());
|
2016-04-13 08:27:17 +02:00
|
|
|
if (type->isReferenceType() || type->isIntegralOrEnumerationType() || type->isPointerType()
|
|
|
|
|| type->isTemplateTypeParmType() || type->isDependentType() || type->isBuiltinType()
|
|
|
|
|| type->isScalarType())
|
|
|
|
{
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// ignore stuff that forms part of the stable URE interface
|
|
|
|
if (isInUnoIncludeFile(compiler.getSourceManager().getSpellingLoc(
|
|
|
|
functionDecl->getCanonicalDecl()->getNameInfo().getLoc()))) {
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
}
|
2016-06-28 18:54:31 +02:00
|
|
|
loplugin::DeclCheck dc(functionDecl);
|
2016-04-13 08:27:17 +02:00
|
|
|
std::string aFunctionName = functionDecl->getQualifiedNameAsString();
|
|
|
|
// function is passed as parameter to another function
|
2016-06-28 18:54:31 +02:00
|
|
|
if (dc.Function("ImplColMonoFnc").Class("GDIMetaFile").GlobalNamespace()
|
|
|
|
|| (dc.Function("darkColor").Class("SvxBorderLine").Namespace("editeng")
|
|
|
|
.GlobalNamespace())
|
2016-04-13 08:27:17 +02:00
|
|
|
|| aFunctionName.compare(0, 8, "xforms::") == 0)
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
// not sure how to exclude this yet, returns copy of one of it's params
|
2016-06-28 18:54:31 +02:00
|
|
|
if (dc.Function("sameDistColor").GlobalNamespace()
|
|
|
|
|| dc.Function("sameColor").GlobalNamespace()
|
|
|
|
|| (dc.Operator(OO_Call).Struct("StringIdentity").AnonymousNamespace()
|
|
|
|
.Namespace("pcr").GlobalNamespace())
|
|
|
|
|| (dc.Function("accumulate").Namespace("internal")
|
|
|
|
.Namespace("slideshow").GlobalNamespace())
|
|
|
|
|| (dc.Function("lerp").Namespace("internal").Namespace("slideshow")
|
|
|
|
.GlobalNamespace()))
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
// depends on a define
|
2016-06-28 18:54:31 +02:00
|
|
|
if (dc.Function("GetSharedFileURL").Class("SfxObjectShell")
|
|
|
|
.GlobalNamespace())
|
|
|
|
{
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-06-28 18:54:31 +02:00
|
|
|
}
|
2016-04-13 08:27:17 +02:00
|
|
|
mbInsideFunctionDecl = true;
|
|
|
|
mbFoundDisqualifier = false;
|
|
|
|
TraverseStmt(functionDecl->getBody());
|
|
|
|
mbInsideFunctionDecl = false;
|
|
|
|
|
|
|
|
if (mbFoundDisqualifier)
|
2016-05-05 09:46:12 +02:00
|
|
|
return;
|
2016-04-13 08:27:17 +02:00
|
|
|
|
|
|
|
report(
|
|
|
|
DiagnosticsEngine::Warning,
|
|
|
|
"rather return %0 from function %1 %2 by const& than by value, to avoid unnecessary copying",
|
|
|
|
functionDecl->getSourceRange().getBegin())
|
|
|
|
<< type.getAsString() << aFunctionName << type->getTypeClassName() << functionDecl->getSourceRange();
|
|
|
|
|
|
|
|
// display the location of the class member declaration so I don't have to search for it by hand
|
|
|
|
if (functionDecl->getSourceRange().getBegin() != functionDecl->getCanonicalDecl()->getSourceRange().getBegin())
|
|
|
|
{
|
|
|
|
report(
|
|
|
|
DiagnosticsEngine::Note,
|
|
|
|
"rather return by const& than by value",
|
|
|
|
functionDecl->getCanonicalDecl()->getSourceRange().getBegin())
|
|
|
|
<< functionDecl->getCanonicalDecl()->getSourceRange();
|
2015-02-05 16:53:30 +01:00
|
|
|
}
|
|
|
|
}
|
2014-05-19 10:02:29 +02:00
|
|
|
|
2015-02-05 16:53:30 +01:00
|
|
|
bool PassStuffByRef::VisitLambdaExpr(const LambdaExpr * expr) {
|
|
|
|
if (ignoreLocation(expr)) {
|
|
|
|
return true;
|
|
|
|
}
|
2015-02-09 10:40:07 +01:00
|
|
|
for (auto i(expr->capture_begin()); i != expr->capture_end(); ++i) {
|
|
|
|
if (i->getCaptureKind() == LambdaCaptureKind::LCK_ByCopy) {
|
2015-12-08 22:56:02 +01:00
|
|
|
auto const t = i->getCapturedVar()->getType();
|
|
|
|
if (isFat(t)) {
|
2015-02-05 16:53:30 +01:00
|
|
|
report(
|
|
|
|
DiagnosticsEngine::Warning,
|
2015-12-08 22:56:02 +01:00
|
|
|
("%0 capture of %1 variable by copy, rather use capture"
|
2015-02-05 16:53:30 +01:00
|
|
|
" by reference---UNLESS THE LAMBDA OUTLIVES THE VARIABLE"),
|
2015-02-09 10:40:07 +01:00
|
|
|
i->getLocation())
|
2015-12-08 22:56:02 +01:00
|
|
|
<< (i->isImplicit() ? "implicit" : "explicit") << t
|
2015-02-05 16:53:30 +01:00
|
|
|
<< expr->getSourceRange();
|
|
|
|
}
|
|
|
|
}
|
2014-03-06 15:29:08 +02:00
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2015-12-08 22:56:02 +01:00
|
|
|
bool PassStuffByRef::isFat(QualType type) {
|
2015-03-03 08:55:35 +01:00
|
|
|
if (!type->isRecordType()) {
|
2015-02-05 16:53:30 +01:00
|
|
|
return false;
|
|
|
|
}
|
2015-12-08 22:56:02 +01:00
|
|
|
if ((loplugin::TypeCheck(type).Class("OUString").Namespace("rtl")
|
|
|
|
.GlobalNamespace())
|
|
|
|
|| (loplugin::TypeCheck(type).Class("OString").Namespace("rtl")
|
|
|
|
.GlobalNamespace())
|
|
|
|
|| (loplugin::TypeCheck(type).Class("Sequence").Namespace("uno")
|
|
|
|
.Namespace("star").Namespace("sun").Namespace("com")
|
|
|
|
.GlobalNamespace()))
|
2015-02-05 16:53:30 +01:00
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
if (type->isIncompleteType()) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
Type const * t2 = type.getTypePtrOrNull();
|
|
|
|
return t2 != nullptr
|
|
|
|
&& compiler.getASTContext().getTypeSizeInChars(t2).getQuantity() > 64;
|
|
|
|
}
|
|
|
|
|
2016-05-05 09:46:12 +02:00
|
|
|
bool PassStuffByRef::isPrimitiveConstRef(QualType type) {
|
|
|
|
if (type->isIncompleteType()) {
|
|
|
|
return false;
|
|
|
|
}
|
2016-06-08 17:14:34 +02:00
|
|
|
const clang::ReferenceType* referenceType = type->getAs<ReferenceType>();
|
|
|
|
if (referenceType == nullptr) {
|
2016-05-05 09:46:12 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
QualType pointeeQT = referenceType->getPointeeType();
|
|
|
|
if (!pointeeQT.isConstQualified()) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
if (!pointeeQT->isFundamentalType()) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
// ignore double for now, some of our code seems to believe it is cheaper to pass by ref
|
2016-06-13 19:22:12 +02:00
|
|
|
const BuiltinType* builtinType = pointeeQT->getAs<BuiltinType>();
|
2016-05-05 09:46:12 +02:00
|
|
|
return builtinType->getKind() != BuiltinType::Kind::Double;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2016-04-14 11:59:19 +02:00
|
|
|
loplugin::Plugin::Registration< PassStuffByRef > X("passstuffbyref");
|
2014-03-06 15:29:08 +02:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|