Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
1975ff8b
Commit
1975ff8b
authored
May 01, 2008
by
Robert Griesemer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- completed syntax for import declarations
- fixed a typo SVN=117439
parent
38c083c1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
doc/go_lang.txt
doc/go_lang.txt
+5
-3
No files found.
doc/go_lang.txt
View file @
1975ff8b
...
...
@@ -1512,7 +1512,7 @@ Switch statements
Switches provide multi-way execution.
SwitchStat = "switch" [ [ SimpleStat ";" ]
"
Expression ] "{" { CaseClause } "}" .
SwitchStat = "switch" [ [ SimpleStat ";" ] Expression ] "{" { CaseClause } "}" .
CaseClause = CaseList StatementList [ ";" ] [ "fallthrough" [ ";" ] ] .
CaseList = Case { Case } .
Case = ( "case" ExpressionList | "default" ) ":" .
...
...
@@ -1686,6 +1686,7 @@ array elements (the values).
TODO: is this right?
Break statements
----
...
...
@@ -1762,8 +1763,9 @@ Import declarations
A program can gain access to exported items from another package
through an import declaration:
ImportDecl = "import" [ "." | PackageName ] PackageFileName .
PackageFileName = string_lit .
ImportDecl = "import" ( ImportSpec | "(" ImportSpecList [ ";" ] ")" ) .
ImportSpec = [ "." | PackageName ] PackageFileName .
ImportSpecList = ImportSpec { ";" ImportSpec } .
An import statement makes the exported contents of the named
package file accessible in this package.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment