* Publish the VB Language spec

This publishes the markdown source from the vblang repository on docs.

* Fix build errors
This commit is contained in:
Bill Wagner 2017-07-22 08:13:28 -04:00 коммит произвёл GitHub
Родитель b61ddab618
Коммит cc6053c654
13 изменённых файлов: 172 добавлений и 20 удалений

1
.gitignore поставляемый
Просмотреть файл

@ -215,6 +215,7 @@ api/
_themes/
_themes.pdf/
_csharplang/
_vblang/
log/
.optemp/
.openpublishing.buildcore.ps1

Просмотреть файл

@ -91,6 +91,11 @@
"path_to_root": "_csharplang",
"url": "https://github.com/dotnet/csharplang",
"branch": "master"
},
{
"path_to_root": "_vblang",
"url": "https://github.com/dotnet/vblang",
"branch": "master"
}
],
"dependent_packages": [

Просмотреть файл

@ -40,6 +40,18 @@
"**/includes/**"
]
},
{
"files": [
"**/*.md"
],
"src": "_vblang/spec",
"dest": "visual-basic/reference/language-specification",
"exclude": [
"README.md",
"LICENSE.md",
"**/includes/**"
]
},
{
"files": [
"core/**/*.md"
@ -108,11 +120,13 @@
"fileMetadata": {
"ms.prod": {
"api/**.yml": ".net",
"_csharplang/spec/*.md": ".net"
"_csharplang/spec/*.md": ".net",
"_vblang/spec/*.md": ".net"
},
"ms.topic": {
"api/**.yml": "managed-reference",
"_csharplang/spec/*.md": "language-reference"
"_csharplang/spec/*.md": "language-reference",
"_vblang/spec/*.md": "language-reference"
},
"langs": {
"api/**.yml": ["csharp", "vb", "cpp"]
@ -121,16 +135,20 @@
"api/**.yml": "NOINDEX, NOFOLLOW"
},
"ms.author": {
"_csharplang/spec/*.md": "wiwagn"
"_csharplang/spec/*.md": "wiwagn",
"_vblang/spec/*.md": "wiwagn"
},
"ms.technology": {
"_csharplong/spec/*.md": "devlang-csharp"
"_csharplang/spec/*.md": "devlang-csharp",
"_vblang/spec/*.md": "devlang-visual-basic"
},
"ms.date": {
"_csharplang/spec/*.md": "07/01/2017"
"_csharplang/spec/*.md": "07/01/2017",
"_vblang/spec/*.md": "07/21/2017"
},
"open_to_public_contributors": {
"_csharplang/spec/*.md": false
"_csharplang/spec/*.md": false,
"_vblang/spec/*.md": false
}
},
"dest": "_site",

Просмотреть файл

@ -32,7 +32,7 @@ The following example shows the complete query operation. The complete operation
- A query is not executed until you iterate over the query variable, for example, in a `foreach` statement. For more information, see [Introduction to LINQ queries](../programming-guide/concepts/linq/introduction-to-linq-queries.md).
- At compile time, query expressions are converted to Standard Query Operator method calls according to the rules set forth in the C# specification. Any query that can be expressed by using query syntax can also be expressed by using method syntax. However, in most cases query syntax is more readable and concise. For more information, see [C# language specification](../language-reference/language-specification.md) and [Standard query operators overview](../programming-guide/concepts/linq/standard-query-operators-overview.md).
- At compile time, query expressions are converted to Standard Query Operator method calls according to the rules set forth in the C# specification. Any query that can be expressed by using query syntax can also be expressed by using method syntax. However, in most cases query syntax is more readable and concise. For more information, see [C# language specification](../language-reference/language-specification/index.md) and [Standard query operators overview](../programming-guide/concepts/linq/standard-query-operators-overview.md).
- As a rule when you write LINQ queries, we recommend that you use query syntax whenever possible and method syntax whenever necessary. There is no semantic or performance difference between the two different forms. Query expressions are often more readable than equivalent expressions written in method syntax.

Просмотреть файл

@ -43,7 +43,7 @@ The following example shows the complete query operation. The complete operation
- A query is not executed until you iterate over the query variable, for example, in a `foreach` statement. For more information, see [Introduction to LINQ queries](introduction-to-linq-queries.md).
- At compile time, query expressions are converted to Standard Query Operator method calls according to the rules set forth in the C# specification. Any query that can be expressed by using query syntax can also be expressed by using method syntax. However, in most cases query syntax is more readable and concise. For more information, see [C# language specification](../../../language-reference/language-specification.md) and [Standard query operators overview](standard-query-operators-overview.md).
- At compile time, query expressions are converted to Standard Query Operator method calls according to the rules set forth in the C# specification. Any query that can be expressed by using query syntax can also be expressed by using method syntax. However, in most cases query syntax is more readable and concise. For more information, see [C# language specification](../../../language-reference/language-specification/index.md) and [Standard query operators overview](standard-query-operators-overview.md).
- As a rule when you write LINQ queries, we recommend that you use query syntax whenever possible and method syntax whenever necessary. There is no semantic or performance difference between the two different forms. Query expressions are often more readable than equivalent expressions written in method syntax.

Просмотреть файл

@ -1059,7 +1059,7 @@
##### [/win32resource](visual-basic/reference/command-line-compiler/win32resource.md)
#### [Compiler Options Listed by Category](visual-basic/reference/command-line-compiler/compiler-options-listed-by-category.md)
### [.NET Framework Reference Information](visual-basic/reference/net-framework-reference-information.md)
### [Language Specification](visual-basic/reference/language-specification.md)
### [Language Specification](visual-basic/reference/language-specification/)
## [Sample Applications](visual-basic/sample-applications.md)
## [Walkthroughs](visual-basic/walkthroughs.md)

Просмотреть файл

@ -38,17 +38,17 @@ translation.priority.mt:
- "tr-tr"
---
# End of statement expected
The statement is syntactically complete, but an additional programming element follows the element that completes the statement. A line terminator is required at the end of every statement.
The statement is syntactically complete, but an additional programming element follows the element that completes the statement. A line terminator is required at the end of every statement.
A line terminator divides the characters of a Visual Basic source file into lines. Examples of line terminators are the Unicode carriage return character (&HD), the Unicode linefeed character (&HA), and the Unicode carriage return character followed by the Unicode linefeed character. For more information about line terminators, see the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification.md).
A line terminator divides the characters of a Visual Basic source file into lines. Examples of line terminators are the Unicode carriage return character (&HD), the Unicode linefeed character (&HA), and the Unicode carriage return character followed by the Unicode linefeed character. For more information about line terminators, see the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification/index.md).
**Error ID:** BC30205
**Error ID:** BC30205
## To correct this error
## To correct this error
1. Check to see if two different statements have inadvertently been put on the same line.
1. Check to see if two different statements have inadvertently been put on the same line.
2. Insert a line terminator after the element that completes the statement.
2. Insert a line terminator after the element that completes the statement.
## See Also
[How to: Break and Combine Statements in Code](../../../visual-basic/programming-guide/program-structure/how-to-break-and-combine-statements-in-code.md)

Просмотреть файл

@ -72,7 +72,7 @@ IntelliSense when Option Infer is on
IntelliSense when Option Infer is off
> [!NOTE]
> When a variable is declared as an `Object`, the run-time type can change while the program is running. [!INCLUDE[vbprvb](~/includes/vbprvb-md.md)] performs operations called *boxing* and *unboxing* to convert between an `Object` and a value type, which makes execution slower. For information about boxing and unboxing, see the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification.md).
> When a variable is declared as an `Object`, the run-time type can change while the program is running. [!INCLUDE[vbprvb](~/includes/vbprvb-md.md)] performs operations called *boxing* and *unboxing* to convert between an `Object` and a value type, which makes execution slower. For information about boxing and unboxing, see the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification/index.md).
Type inference applies at the procedure level, and does not apply outside a procedure in a class, structure, module, or interface.

Просмотреть файл

@ -107,7 +107,7 @@ Option Strict { On | Off }
An object is late bound when it is assigned to a property or method of a variable that is declared to be of type `Object`. For more information, see [Early and Late Binding](../../../visual-basic/programming-guide/language-features/early-late-binding/index.md).
## Implicit Object Type Errors
Implicit object type errors occur when an appropriate type cannot be inferred for a declared variable, so a type of `Object` is inferred. This primarily occurs when you use a `Dim` statement to declare a variable without using an `As` clause, and `Option Infer` is off. For more information, see [Option Infer Statement](../../../visual-basic/language-reference/statements/option-infer-statement.md) and the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification.md).
Implicit object type errors occur when an appropriate type cannot be inferred for a declared variable, so a type of `Object` is inferred. This primarily occurs when you use a `Dim` statement to declare a variable without using an `As` clause, and `Option Infer` is off. For more information, see [Option Infer Statement](../../../visual-basic/language-reference/statements/option-infer-statement.md) and the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification/index.md).
For method parameters, the `As` clause is optional if `Option Strict` is off. However, if any one parameter uses an `As` clause, they all must use it. If `Option Strict` is on, the `As` clause is required for every parameter definition.

Просмотреть файл

@ -446,7 +446,7 @@ End Class
Iterators do not support the <xref:System.Collections.IEnumerator.Reset%2A?displayProperty=fullName> method. To re-iterate from the start, you must obtain a new iterator.
For additional information, see the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification.md).
For additional information, see the [Visual Basic Language Specification](../../../visual-basic/reference/language-specification/index.md).
## <a name="BKMK_UseOfIterators"></a> Use of Iterators
Iterators enable you to maintain the simplicity of a `For Each` loop when you need to use complex code to populate a list sequence. This can be useful when you want to do the following:

Просмотреть файл

@ -47,7 +47,7 @@ This section provides links to reference information about various aspects of [!
[.NET Framework Reference Information](../../visual-basic/reference/net-framework-reference-information.md)
Provides links to information on working with the [!INCLUDE[dnprdnshort](~/includes/dnprdnshort-md.md)] class library.
[Visual Basic Language Specification](../../visual-basic/reference/language-specification.md)
[Visual Basic Language Specification](../../visual-basic/reference/language-specification/index.md)
Provides links to the complete [!INCLUDE[vbprvb](~/includes/vbprvb-md.md)] language specification, which contains detailed information on all aspects of the language.
## Reference

Просмотреть файл

@ -40,5 +40,13 @@ The [!INCLUDE[vbprvb](~/includes/vbprvb-md.md)] Language Specification is the au
The specification is available on the [Microsoft Download Center](http://go.microsoft.com/fwlink/?LinkId=188623).
This site contains the [VB 11 specification](../../../../_vblang/spec/introduction.md). It is built from the markdown files contained in [the dotnet/vblang GitHub repository](https://github.com/dotnet/vb/blob/master/spec/README.md).
Issues on the specification should be created in the [dotnet/vblang](https://github.com/dotnet/vblang/issues) repository. Or, if you are interested
in fixing any errors you find, you may submit a [Pull Request](https://github.com/dotnet/vblang/pulls) to the same repository.
## See Also
[Visual Basic Language Reference](../../visual-basic/language-reference/index.md)
[Visual Basic Language Reference](../../../visual-basic/language-reference/index.md)
>[!div class="step-by-step"]
[Next](../../../../_vblang/spec/introduction.md)

Просмотреть файл

@ -0,0 +1,120 @@
# [Visual Basic Language Specification](index.md)
## [Introduction](../../../../_vblang/spec/introduction.md#introduction)
### [Grammar Notation](../../../../_vblang/spec/introduction.md#grammar-notation)
### [Compatibility](../../../../_vblang/spec/introduction.md#compatibility)
## [Lexical Grammar](../../../../_vblang/spec/lexical-grammar.md#lexical-grammar)
### [Characters and Lines](../../../../_vblang/spec/lexical-grammar.md#characters-and-lines)
### [Identifiers](../../../../_vblang/spec/lexical-grammar.md#identifiers)
### [Keywords](../../../../_vblang/spec/lexical-grammar.md#keywords)
### [Literals](../../../../_vblang/spec/lexical-grammar.md#literals)
### [Separators](../../../../_vblang/spec/lexical-grammar.md#separators)
### [Operator Characters](../../../../_vblang/spec/lexical-grammar.md#operator-characters)
## [Preprocessing Directives](../../../../_vblang/spec/preprocessing-directives.md#preprocessing-directives)
### [Conditional Compilation](../../../../_vblang/spec/preprocessing-directives.md#conditional-compilation)
### [External Source Directives](../../../../_vblang/spec/preprocessing-directives.md#external-source-directives)
### [Region Directives](../../../../_vblang/spec/preprocessing-directives.md#region-directives)
### [External Checksum Directives](../../../../_vblang/spec/preprocessing-directives.md#external-checksum-directives)
## [General Concepts](../../../../_vblang/spec/general-concepts.md#general-concepts)
### [Declarations](../../../../_vblang/spec/general-concepts.md#declarations)
### [Scope](../../../../_vblang/spec/general-concepts.md#scope)
### [Inheritance](../../../../_vblang/spec/general-concepts.md#inheritance)
### [Implementation](../../../../_vblang/spec/general-concepts.md#implementation)
### [Polymorphism](../../../../_vblang/spec/general-concepts.md#polymorphism)
### [Accessibility](../../../../_vblang/spec/general-concepts.md#accessibility)
### [Type and Namespace Names](../../../../_vblang/spec/general-concepts.md#type-and-namespace-names)
### [Variables](../../../../_vblang/spec/general-concepts.md#variables)
### [Generic Types and Methods](../../../../_vblang/spec/general-concepts.md#generic-types-and-methods)
## [Attributes](../../../../_vblang/spec/attributes.md#attributes)
### [Attribute Classes](../../../../_vblang/spec/attributes.md#attribute-classes)
### [Attribute Blocks](../../../../_vblang/spec/attributes.md#attribute-blocks)
## [Source Files and Namespaces](../../../../_vblang/spec/source-files-and-namespaces.md#source-files-and-namespaces)
### [Program Startup and Termination](../../../../_vblang/spec/source-files-and-namespaces.md#program-startup-and-termination)
### [Compilation Options](../../../../_vblang/spec/source-files-and-namespaces.md#compilation-options)
### [Imports Statement](../../../../_vblang/spec/source-files-and-namespaces.md#imports-statement)
### [Namespaces](../../../../_vblang/spec/source-files-and-namespaces.md#namespaces)
## [Types](../../../../_vblang/spec/types.md#types)
### [Value Types and Reference Types](../../../../_vblang/spec/types.md#value-types-and-reference-types)
### [Interface Implementation](../../../../_vblang/spec/types.md#interface-implementation)
### [Primitive Types](../../../../_vblang/spec/types.md#primitive-types)
### [Enumerations](../../../../_vblang/spec/types.md#enumerations)
### [Classes](../../../../_vblang/spec/types.md#classes)
### [Structures](../../../../_vblang/spec/types.md#structures)
### [Standard Modules](../../../../_vblang/spec/types.md#standard-modules)
### [Interfaces](../../../../_vblang/spec/types.md#interfaces)
### [Arrays](../../../../_vblang/spec/types.md#arrays)
### [Delegates](../../../../_vblang/spec/types.md#delegates)
### [Partial types](../../../../_vblang/spec/types.md#partial-types)
### [Constructed Types](../../../../_vblang/spec/types.md#constructed-types)
### [Special Types](../../../../_vblang/spec/types.md#special-types)
## [Conversions](../../../../_vblang/spec/conversions.md#conversions)
### [Implicit and Explicit Conversions](../../../../_vblang/spec/conversions.md#implicit-and-explicit-conversions)
### [Boolean Conversions](../../../../_vblang/spec/conversions.md#boolean-conversions)
### [Numeric Conversions](../../../../_vblang/spec/conversions.md#numeric-conversions)
### [Reference Conversions](../../../../_vblang/spec/conversions.md#reference-conversions)
### [Array Conversions](../../../../_vblang/spec/conversions.md#array-conversions)
### [Value Type Conversions](../../../../_vblang/spec/conversions.md#value-type-conversions)
### [String Conversions](../../../../_vblang/spec/conversions.md#string-conversions)
### [Widening Conversions](../../../../_vblang/spec/conversions.md#widening-conversions)
### [Narrowing Conversions](../../../../_vblang/spec/conversions.md#narrowing-conversions)
### [Type Parameter Conversions](../../../../_vblang/spec/conversions.md#type-parameter-conversions)
### [User-Defined Conversions](../../../../_vblang/spec/conversions.md#user-defined-conversions)
### [Native Conversions](../../../../_vblang/spec/conversions.md#native-conversions)
### [Dominant Type](../../../../_vblang/spec/conversions.md#dominant-type)
## [Type Members](../../../../_vblang/spec/type-members.md#type-members)
### [Interface Method Implementation](../../../../_vblang/spec/type-members.md#interface-method-implementation)
### [Methods](../../../../_vblang/spec/type-members.md#methods)
### [Constructors](../../../../_vblang/spec/type-members.md#constructors)
### [Events](../../../../_vblang/spec/type-members.md#events)
### [Constants](../../../../_vblang/spec/type-members.md#constants)
### [Instance and Shared Variables](../../../../_vblang/spec/type-members.md#instance-and-shared-variables)
### [Properties](../../../../_vblang/spec/type-members.md#properties)
### [Operators](../../../../_vblang/spec/type-members.md#operators)
## [Statements](../../../../_vblang/spec/statements.md#statements)
### [Control Flow](../../../../_vblang/spec/statements.md#control-flow)
### [Local Declaration Statements](../../../../_vblang/spec/statements.md#local-declaration-statements)
### [With Statement](../../../../_vblang/spec/statements.md#with-statement)
### [SyncLock Statement](../../../../_vblang/spec/statements.md#synclock-statement)
### [Event Statements](../../../../_vblang/spec/statements.md#event-statements)
### [Assignment Statements](../../../../_vblang/spec/statements.md#assignment-statements)
### [Invocation Statements](../../../../_vblang/spec/statements.md#invocation-statements)
### [Conditional Statements](../../../../_vblang/spec/statements.md#conditional-statements)
### [Loop Statements](../../../../_vblang/spec/statements.md#loop-statements)
### [Exception-Handling Statements](../../../../_vblang/spec/statements.md#exception-handling-statements)
### [Branch Statements](../../../../_vblang/spec/statements.md#branch-statements)
### [Array-Handling Statements](../../../../_vblang/spec/statements.md#array-handling-statements)
### [Using statement](../../../../_vblang/spec/statements.md#using-statement)
### [Await Statement](../../../../_vblang/spec/statements.md#await-statement)
### [Yield Statement](../../../../_vblang/spec/statements.md#yield-statement)
## [Expressions](../../../../_vblang/spec/expressions.md#expressions)
### [Expression Classifications](../../../../_vblang/spec/expressions.md#expression-classifications)
### [Constant Expressions](../../../../_vblang/spec/expressions.md#constant-expressions)
### [Late-Bound Expressions](../../../../_vblang/spec/expressions.md#late-bound-expressions)
### [Simple Expressions](../../../../_vblang/spec/expressions.md#simple-expressions)
### [Type Expressions](../../../../_vblang/spec/expressions.md#type-expressions)
### [Member Access Expressions](../../../../_vblang/spec/expressions.md#member-access-expressions)
### [Dictionary Member Access Expressions](../../../../_vblang/spec/expressions.md#dictionary-member-access-expressions)
### [Invocation Expressions](../../../../_vblang/spec/expressions.md#invocation-expressions)
### [Index Expressions](../../../../_vblang/spec/expressions.md#index-expressions)
### [New Expressions](../../../../_vblang/spec/expressions.md#new-expressions)
### [Cast Expressions](../../../../_vblang/spec/expressions.md#cast-expressions)
### [Operator Expressions](../../../../_vblang/spec/expressions.md#operator-expressions)
### [Arithmetic Operators](../../../../_vblang/spec/expressions.md#arithmetic-operators)
### [Relational Operators](../../../../_vblang/spec/expressions.md#relational-operators)
### [Like Operator](../../../../_vblang/spec/expressions.md#like-operator)
### [Concatenation Operator](../../../../_vblang/spec/expressions.md#concatenation-operator)
### [Logical Operators](../../../../_vblang/spec/expressions.md#logical-operators)
### [Shift Operators](../../../../_vblang/spec/expressions.md#shift-operators)
### [Boolean Expressions](../../../../_vblang/spec/expressions.md#boolean-expressions)
### [Lambda Expressions](../../../../_vblang/spec/expressions.md#lambda-expressions)
### [Query Expressions](../../../../_vblang/spec/expressions.md#query-expressions)
### [Conditional Expressions](../../../../_vblang/spec/expressions.md#conditional-expressions)
### [XML Literal Expressions](../../../../_vblang/spec/expressions.md#xml-literal-expressions)
### [XML Member Access Expressions](../../../../_vblang/spec/expressions.md#xml-member-access-expressions)
### [Await Operator](../../../../_vblang/spec/expressions.md#await-operator)
## [Documentation Comments](../../../../_vblang/spec/documentation-comments.md#documentation-comments)
### [Documentation Comment Format](../../../../_vblang/spec/documentation-comments.md#documentation-comment-format)
### [Recommended tags](../../../../_vblang/spec/documentation-comments.md#recommended-tags)
### [ID Strings](../../../../_vblang/spec/documentation-comments.md#id-strings)
### [Documentation comments example](../../../../_vblang/spec/documentation-comments.md#documentation-comments-example)
## Grammar: [vb.html](http://ljw1004.github.io/vbspec/vb.html). Or download in ANTLR format: [vb.g4](vb.g4?raw=true).