1

I'm trying to create an event source class for SLAB using C++. I've already tried creating one using C# so I'm really clueless on the following issue.

So basically I'm using the System::Diagnostic::Tracing EventSource class provided in .Net. However, when I extend the said EventSource class, it results to the following warning

warning C4538: 'cli::array<Type,dimension> ^': const/volatile qualifiers on this type are not supported
with
      [
          Type=System::Diagnostics::Tracing::EventSource::EventMetadata,
          dimension=1
      ]
This diagnostic occurred while importing type 'System::Diagnostics::Tracing::EventSource ' from assembly 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.   

So why does this warning shows up when I'm just extending a class and how can I remove it?

Also, could someone kindly show me an example of creating a SLAB EventSource in C++? I've searched all over the net yet I cannot find a single one.

I'm really a beginner with C++ especially with managed C++ so I'm really sorry if this question may seem stupid.

  • 1
    Is this the full warning text? – deviantfan May 29 '14 at 10:50
  • 1
    Duplicate? http://stackoverflow.com/questions/12151060/seemingly-inappropriate-compilation-warning-with-c-cli Or do you have a const or volatile in the wrong place? – doctorlove May 29 '14 at 10:55
  • Sorry the warning text was cut in the original post, already updated it. @doctorlove, I'm not really sure regarding that but all that I'm doing is extending the EventSource class and the warning already shows – user3687031 May 29 '14 at 11:02
  • @doctorlove comment about duplicate leads to someone saying this is a 'compiler bug', so disable the warning with a pragma...It would be nice if someone could reference this compiler bug so my code can be documented as to why i'm disabling this warning with a pragma... – Aaron Hudon Nov 20 '15 at 19:57

0 Answers0