File tree Expand file tree Collapse file tree 4 files changed +6
-5
lines changed Expand file tree Collapse file tree 4 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -436,10 +436,10 @@ Modified Compiler Flags
436
436
to utilize these vector libraries. The behavior for all other vector function
437
437
libraries remains unchanged.
438
438
439
- - The ``-Wnontrivial-memaccess `` warning has been updated to also warn about
439
+ - The ``-Wnontrivial-memcall `` warning has been added to warn about
440
440
passing non-trivially-copyable destrination parameter to ``memcpy ``,
441
441
``memset `` and similar functions for which it is a documented undefined
442
- behavior.
442
+ behavior. It is implied by `` -Wnontrivial-memaccess ``
443
443
444
444
Removed Compiler Flags
445
445
-------------------------
Original file line number Diff line number Diff line change @@ -683,7 +683,8 @@ def SizeofArrayDecay : DiagGroup<"sizeof-array-decay">;
683
683
def SizeofPointerMemaccess : DiagGroup<"sizeof-pointer-memaccess">;
684
684
def MemsetTransposedArgs : DiagGroup<"memset-transposed-args">;
685
685
def DynamicClassMemaccess : DiagGroup<"dynamic-class-memaccess">;
686
- def NonTrivialMemaccess : DiagGroup<"nontrivial-memaccess">;
686
+ def NonTrivialMemcall : DiagGroup<"nontrivial-memcall">;
687
+ def NonTrivialMemaccess : DiagGroup<"nontrivial-memaccess", [NonTrivialMemcall]>;
687
688
def SuspiciousBzero : DiagGroup<"suspicious-bzero">;
688
689
def SuspiciousMemaccess : DiagGroup<"suspicious-memaccess",
689
690
[SizeofPointerMemaccess, DynamicClassMemaccess,
Original file line number Diff line number Diff line change @@ -798,7 +798,7 @@ def warn_cstruct_memaccess : Warning<
798
798
def warn_cxxstruct_memaccess : Warning<
799
799
"first argument in call to "
800
800
"%0 is a pointer to non-trivially copyable type %1">,
801
- InGroup<NonTrivialMemaccess >;
801
+ InGroup<NonTrivialMemcall >;
802
802
def note_nontrivial_field : Note<
803
803
"field is non-trivial to %select{copy|default-initialize}0">;
804
804
def err_non_trivial_c_union_in_invalid_context : Error<
Original file line number Diff line number Diff line change 1
- // RUN: %clang_cc1 -fsyntax-only -verify -std=c++11 -Wnontrivial-memaccess %s
1
+ // RUN: %clang_cc1 -fsyntax-only -verify -std=c++11 -Wnontrivial-memcall %s
2
2
3
3
extern " C" void *bzero (void *, unsigned );
4
4
extern " C" void *memset (void *, int , unsigned );
You can’t perform that action at this time.
0 commit comments