Closed
Bug 692782
Opened 13 years ago
Closed 13 years ago
Bug 690670 broke clang builds
Categories
(Core :: XPCOM, defect)
Tracking
()
RESOLVED
FIXED
mozilla10
People
(Reporter: ehsan.akhgari, Assigned: ehsan.akhgari)
References
Details
Attachments
(1 file)
(deleted),
patch
|
cjones
:
review+
|
Details | Diff | Splinter Review |
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/sandbox/SandboxHal.cpp:1:
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/sandbox/SandboxHal.cpp:41:
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/Hal.h:45:
../dist/include/nsTArray.h:1338:5: error: use of undeclared identifier 'AppendElements'
AppendElements(other);
^
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/sandbox/SandboxHal.cpp:1:
/Users/ehsanakhgari/moz/mozilla-central/hal/sandbox/SandboxHal.cpp:65:35: note: in instantiation of function template specialization 'AutoInfallibleTArray<unsigned
int, 8>::AutoInfallibleTArray<nsTArrayDefaultAllocator>' requested here
AutoInfallibleTArray<uint32, 8> p(pattern);
^
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/sandbox/SandboxHal.cpp:1:
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/sandbox/SandboxHal.cpp:41:
In file included from /Users/ehsanakhgari/moz/mozilla-central/hal/Hal.h:45:
../dist/include/nsTArray.h:824:14: note: must qualify identifier to find this declaration in dependent base class
elem_type *AppendElements(const Item* array, size_type arrayLen) {
^
../dist/include/nsTArray.h:835:14: note: must qualify identifier to find this declaration in dependent base class
elem_type *AppendElements(const nsTArray<Item, Allocator>& array) {
^
../dist/include/nsTArray.h:848:14: note: must qualify identifier to find this declaration in dependent base class
elem_type *AppendElements(size_type count) {
^
2 warnings and 1 error generated.
Assignee | ||
Comment 1•13 years ago
|
||
Comment 2•13 years ago
|
||
FWIW, this patch is also required to build with not-yet-released GCC 4.7, where you get something like:
In file included from /home/froydnj/src/mozilla-central/hal/Hal.h:45:0,
from /home/froydnj/src/mozilla-central/hal/sandbox/SandboxHal.cpp:40:
../dist/include/nsTArray.h: In instantiation of 'AutoInfallibleTArray<E, N>::AutoInfallibleTArray(const nsTArray<E, Allocator>&) [with Allocator = nsTArrayDefaultAllocator; E = unsigned int; unsigned int N = 8u]':
/home/froydnj/src/mozilla-central/hal/sandbox/SandboxHal.cpp:65:44: required from here
../dist/include/nsTArray.h:1315:5: error: 'AppendElements' was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
../dist/include/nsTArray.h:1315:5: note: declarations in dependent base 'nsTArray<unsigned int, nsTArrayInfallibleAllocator>' are not found by unqualified lookup
../dist/include/nsTArray.h:1315:5: note: use 'this->AppendElements' instead
I can verify that this bug is fixed with the provided patch.
Comment on attachment 565535 [details] [diff] [review]
Patch (v1)
Nit: would you please add
> template<class E, PRUint32 N, class Alloc=nsTArrayDefaultAllocator>
> class nsAutoTArray : public nsAutoArrayBase<nsTArray<E, Alloc>, N>
> {
typedef nsAutoArrayBase<nsTArray<E, Alloc>, N> Base;
> public:
> nsAutoTArray() {}
>
> template<typename Allocator>
> nsAutoTArray(const nsTArray<E, Allocator>& other) {
>- AppendElements(other);
and then call
>+ Base::AppendElements(other);
instead? And below.
r=me with that.
Attachment #565535 -
Flags: review?(jones.chris.g) → review+
Assignee | ||
Comment 4•13 years ago
|
||
Target Milestone: --- → mozilla10
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•