This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Use of templates in c code?


On Wed, Feb 13, 2013 at 1:31 PM, Alec Teal <a.teal@warwick.ac.uk> wrote:
> I've been studying/reading gccs code, watching it compile though a debugger and reading. Today I noticed something odd in the c++ parser's file. I saw what appeared to be a template in a .c file.

It's just a filename ... we compile it with a C++ compiler.

Richard.

> I am on a different computer now but it was vec< and occurred about 1/6th of the way in, it should be easy to find.
>
> Is that allowed? Is my main question. I would support a c with templates it'd save macro usage, that could only be good! Or is there some construct of c I do not know of.
>
> Searching for c templates proved fruitless I got loads of c++ results
>
> Alec


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]