Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
38d1c303
Kaydet (Commit)
38d1c303
authored
Ock 12, 2017
tarafından
Stephan Bergmann
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Adapt loplugin:overrideparam to recent Clang trunk change
Change-Id: Ia372e39bc7e51f290a6d631bf0b81fd75f4fdc1d
üst
ff30d20c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
5 deletions
+14
-5
overrideparam.cxx
compilerplugins/clang/overrideparam.cxx
+14
-5
No files found.
compilerplugins/clang/overrideparam.cxx
Dosyayı görüntüle @
38d1c303
...
...
@@ -179,11 +179,20 @@ bool OverrideParam::hasSameDefaultParams(const ParmVarDecl * parmVarDecl, const
{
return
true
;
}
#if CLANG_VERSION >= 30900
return
false
;
#else
return
true
;
// clang3-8 doesn't have EvaluateAsFloat, so we can't be as precise
#endif
return
true
;
// for one, Clang 3.8 doesn't have EvaluateAsFloat; for another, since
// <http://llvm.org/viewvc/llvm-project?view=revision&revision=291318>
// "PR23135: Don't instantiate constexpr functions referenced in
// unevaluated operands where possible", default args are not
// necessarily evaluated, so the above calls to EvaluateAsInt etc. may
// fail (as they do e.g. for SfxViewShell::SetPrinter and derived
// classes' 'SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL' arg,
// include/sfx2/viewsh.hxx; what appears would help is to call
// 'compiler.getSema().MarkDeclarationsReferencedInExpr()' on
// defaultArgExpr and superDefaultArgExpr before any of the calls to
// EvaluateAsInt etc., cf. the implementation of
// Sema::CheckCXXDefaultArgExpr in Clang's lib/Sema/SemaExpr.cpp, but
// that would probably have unwanted side-effects)
}
bool
OverrideParam
::
evaluate
(
const
Expr
*
expr
,
APSInt
&
x
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment