Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 4 additions & 8 deletions docs/error-messages/compiler-errors-2/compiler-error-c2537.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,22 @@
---
description: "Learn more about: Compiler Error C2537"
title: "Compiler Error C2537"
ms.date: "11/04/2016"
ms.date: "03/08/2024"
f1_keywords: ["C2537"]
helpviewer_keywords: ["C2537"]
ms.assetid: aee81d8e-300e-4a8b-b6c4-b3828398b34e
---
# Compiler Error C2537

'specifier' : illegal linkage specification

Possible causes:

1. The linkage specifier is not supported. Only the "C" linkage specifier is supported.

1. "C" linkage is specified for more than one function in a set of overloaded functions. This is not allowed.
The linkage specifier is not supported. Only the "C" and "C++" linkage specifiers are supported.

The following sample generates C2537:

```cpp
// C2537.cpp
// compile with: /c
extern "c" void func(); // C2537
extern "c" void func1(); // C2537
extern "C" void func2(); // OK
extern "C++" void func3(); // OK
```