Skip to content

Commit 5cd3695

Browse files
authored
Merge pull request #5674 from Rageking8/structure-error-references-in-range-c3281-c3350
Structure error references in range [C3281, C3350]
2 parents b72de60 + 9fee0c0 commit 5cd3695

27 files changed

+163
-126
lines changed

docs/error-messages/compiler-errors-2/compiler-error-c3282.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3282"
32
title: "Compiler Error C3282"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3282"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3282"]
66
helpviewer_keywords: ["C3282"]
7-
ms.assetid: bac2ac89-c360-4c24-bb81-c20c62ece9ba
87
---
98
# Compiler Error C3282
109

11-
generic parameter lists can only appear on managed or WinRTclasses, structs, or functions
10+
> generic parameter lists can only appear on managed or WinRTclasses, structs, or functions
11+
12+
## Remarks
1213

1314
A generic parameter list was used incorrectly. For more information, see [Generics](../../extensions/generics-cpp-component-extensions.md).
1415

1516
## Example
1617

17-
The following sample generates C3282 and shows how to fix it.
18+
The following example generates C3282 and shows how to fix it.
1819

1920
```cpp
2021
// C3282.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3283.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3283"
32
title: "Compiler Error C3283"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3283"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3283"]
66
helpviewer_keywords: ["C3283"]
7-
ms.assetid: c51d912c-cde3-4928-904e-26734c8954ce
87
---
98
# Compiler Error C3283
109

11-
'type' : an interface cannot have an instance constructor
10+
> 'type' : an interface cannot have an instance constructor
11+
12+
## Remarks
1213

1314
A CLR [interface](../../extensions/interface-class-cpp-component-extensions.md) cannot have an instance constructor. A static constructor is allowed.
1415

15-
The following sample generates C3283:
16+
## Example
17+
18+
The following example generates C3283:
1619

1720
```cpp
1821
// C3283.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3284.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3284"
32
title: "Compiler Error C3284"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3284"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3284"]
66
helpviewer_keywords: ["C3284"]
7-
ms.assetid: e582f316-e9db-4d27-9c70-fdfa737a9d5f
87
---
98
# Compiler Error C3284
109

11-
the constraints for generic parameter 'parameter' of function 'function' must match the constraints for generic parameter 'parameter' of function 'function'
10+
> the constraints for generic parameter 'parameter' of function 'function' must match the constraints for generic parameter 'parameter' of function 'function'
11+
12+
## Remarks
1213

1314
A virtual generic function must use the same constraints as a virtual function with the same name and set of arguments in the base class.
1415

15-
The following sample generates C3284:
16+
## Example
17+
18+
The following example generates C3284:
1619

1720
```cpp
1821
// C3284.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3285.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,23 @@
11
---
2-
description: "Learn more about: Compiler Error C3285"
32
title: "Compiler Error C3285"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3285"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3285"]
66
helpviewer_keywords: ["C3285"]
7-
ms.assetid: 04e8f210-d67e-4810-b153-e1efe2986c8f
87
---
98
# Compiler Error C3285
109

11-
for each statement cannot operate on variables of type 'type'
10+
> for each statement cannot operate on variables of type 'type'
11+
12+
## Remarks
1213

1314
The `for each` statement repeats a group of embedded statements for each element in an array or an object collection.
1415

1516
See [for each, in](../../dotnet/for-each-in.md) for more information.
1617

1718
## Example
1819

19-
The following sample generates C3285.
20+
The following example generates C3285.
2021

2122
```cpp
2223
// C3285.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3286.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3286"
32
title: "Compiler Error C3286"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3286"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3286"]
66
helpviewer_keywords: ["C3286"]
7-
ms.assetid: 554328c8-cf44-4f7d-a8d2-def74d28ecdd
87
---
98
# Compiler Error C3286
109

1110
> '*specifier*': an iteration variable cannot have any storage-class specifiers
1211
12+
## Remarks
13+
1314
A storage class can't be specified on an iteration variable. For more information, see [Storage classes (C++)](../../cpp/storage-classes-cpp.md) and [for each, in](../../dotnet/for-each-in.md).
1415

1516
## Example
1617

17-
The following sample generates C3286, and also shows correct usage.
18+
The following example generates C3286, and also shows correct usage.
1819

1920
```cpp
2021
// C3286.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3287.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ description: "Describes Microsoft C++ compiler error C3287."
44
ms.date: 09/25/2020
55
f1_keywords: ["C3287"]
66
helpviewer_keywords: ["C3287"]
7-
ms.assetid: c1fa73d2-2c82-4136-a7da-0e75e3b420ad
87
---
98
# Compiler Error C3287
109

@@ -18,7 +17,7 @@ For more information, see [for each, in](../../dotnet/for-each-in.md).
1817

1918
## Example
2019

21-
The following sample generates C3287.
20+
The following example generates C3287.
2221

2322
```cpp
2423
// C3287.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3288.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3288"
32
title: "Compiler Error C3288"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3288"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3288"]
66
helpviewer_keywords: ["C3288"]
7-
ms.assetid: ed08a540-9751-46e1-9cbe-c51d6a49ffab
87
---
98
# Compiler Error C3288
109

11-
'type' : illegal dereference of a handle type
10+
> 'type' : illegal dereference of a handle type
11+
12+
## Remarks
1213

1314
The compiler detected an illegal dereference of a handle type. You can dereference a handle type and assign it to a reference. For more information, see [Tracking Reference Operator](../../extensions/tracking-reference-operator-cpp-component-extensions.md).
1415

1516
## Example
1617

17-
The following sample generates C3288.
18+
The following example generates C3288.
1819

1920
```cpp
2021
// C3288.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3289.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3289"
32
title: "Compiler Error C3289"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3289"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3289"]
66
helpviewer_keywords: ["C3289"]
7-
ms.assetid: 3c1c623b-7fcf-43ab-a89a-8722532a8d29
87
---
98
# Compiler Error C3289
109

11-
'property' : a trivial property cannot be indexed
10+
> 'property' : a trivial property cannot be indexed
11+
12+
## Remarks
1213

1314
A property was declared incorrectly. Accessors must be defined for an indexed property. See [property](../../extensions/property-cpp-component-extensions.md) for more information.
1415

1516
## Example
1617

17-
The following sample generates C3289.
18+
The following example generates C3289.
1819

1920
```cpp
2021
// C3289.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3290.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,23 @@
11
---
2-
description: "Learn more about: Compiler Error C3290"
32
title: "Compiler Error C3290"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3290"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3290"]
66
helpviewer_keywords: ["C3290"]
7-
ms.assetid: 0baf684b-1143-4953-ac99-a2fa267d8017
87
---
98
# Compiler Error C3290
109

11-
'type' : a trivial property cannot have reference type
10+
> 'type' : a trivial property cannot have reference type
11+
12+
## Remarks
1213

1314
A property was declared incorrectly. When you declare a trivial property, the compiler creates a variable that the property will update, and it is not possible to have a tracking reference variable in a class.
1415

1516
See [property](../../extensions/property-cpp-component-extensions.md) and [Tracking Reference Operator](../../extensions/tracking-reference-operator-cpp-component-extensions.md) for more information.
1617

1718
## Example
1819

19-
The following sample generates C3290.
20+
The following example generates C3290.
2021

2122
```cpp
2223
// C3290.cpp

docs/error-messages/compiler-errors-2/compiler-error-c3291.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
---
2-
description: "Learn more about: Compiler Error C3291"
32
title: "Compiler Error C3291"
4-
ms.date: "11/04/2016"
3+
description: "Learn more about: Compiler Error C3291"
4+
ms.date: 11/04/2016
55
f1_keywords: ["C3291"]
66
helpviewer_keywords: ["C3291"]
7-
ms.assetid: ed2e9f89-8dbc-4387-bc26-cc955e840858
87
---
98
# Compiler Error C3291
109

11-
'default' : cannot be the name of a trivial property
10+
> 'default' : cannot be the name of a trivial property
11+
12+
## Remarks
1213

1314
A trivial property cannot be named **`default`**. See [property](../../extensions/property-cpp-component-extensions.md) for more information.
1415

1516
## Example
1617

17-
The following sample generates C3291.
18+
The following example generates C3291.
1819

1920
```cpp
2021
// C3291.cpp

0 commit comments

Comments
 (0)