I can't get my regex to match the header of a c# code file. I basically want need to return the header if it exists.
Example:
#define debug
//****************************************************************************************************
// <copyright file="" company="">
// Copyright (c) . All rights reserved.
// </copyright>
// <project>Engine</project>
//****************************************************************************************************
code here
//some other comment here
more code here
//another comment here
My regex looks like this:
(?:/\\*(?:[^*]|(?:\\*\+[^*/]))*\\*\+/)|(?://.*)
but it only matches this line: //**********************************************************
and not the rest of the comment.
Comments can also end like this "*/"
.
whats wrong with my regex? why doesn't it catch the whole block?