Skip to content
This repository has been archived by the owner on Mar 8, 2020. It is now read-only.

Commit

Permalink
update sdk version and add unicode fixture
Browse files Browse the repository at this point in the history
Signed-off-by: Denys Smirnov <denys@sourced.tech>
  • Loading branch information
Denys Smirnov authored and dennwc committed Apr 8, 2019
1 parent 7177072 commit 3c03f89
Show file tree
Hide file tree
Showing 5 changed files with 418 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions fixtures/unicode.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
package unicode

const v = "𝓏"
140 changes: 140 additions & 0 deletions fixtures/unicode.go.native
Original file line number Diff line number Diff line change
@@ -0,0 +1,140 @@
{ '@type': "File",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 0,
line: 1,
col: 1,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
Package: { '@type': "uast:Position",
offset: 0,
line: 1,
col: 1,
},
},
Comments: ~,
Decls: [
{ '@type': "GenDecl",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 17,
line: 3,
col: 1,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
Lparen: { '@type': "uast:Position",
offset: 0,
line: 0,
col: 0,
},
Rparen: { '@type': "uast:Position",
offset: 0,
line: 0,
col: 0,
},
TokPos: { '@type': "uast:Position",
offset: 17,
line: 3,
col: 1,
},
},
Doc: ~,
Specs: [
{ '@type': "ValueSpec",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 23,
line: 3,
col: 7,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
},
Comment: ~,
Doc: ~,
Names: [
{ '@type': "Ident",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 23,
line: 3,
col: 7,
},
end: { '@type': "uast:Position",
offset: 24,
line: 3,
col: 8,
},
NamePos: { '@type': "uast:Position",
offset: 23,
line: 3,
col: 7,
},
},
Name: "v",
},
],
Type: ~,
Values: [
{ '@type': "BasicLit",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 27,
line: 3,
col: 11,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
ValuePos: { '@type': "uast:Position",
offset: 27,
line: 3,
col: 11,
},
},
Kind: "STRING",
Value: "\"𝓏\"",
},
],
},
],
Tok: "const",
},
],
Doc: ~,
Imports: ~,
Name: { '@type': "Ident",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 8,
line: 1,
col: 9,
},
end: { '@type': "uast:Position",
offset: 15,
line: 1,
col: 16,
},
NamePos: { '@type': "uast:Position",
offset: 8,
line: 1,
col: 9,
},
},
Name: "unicode",
},
Unresolved: ~,
}
128 changes: 128 additions & 0 deletions fixtures/unicode.go.sem.uast
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
{ '@type': "go:File",
'@role': [File],
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 0,
line: 1,
col: 1,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
Package: { '@type': "uast:Position",
offset: 0,
line: 1,
col: 1,
},
},
Comments: ~,
Decls: [
{ '@type': "go:GenDecl",
'@role': [Declaration, Incomplete],
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 17,
line: 3,
col: 1,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
Lparen: { '@type': "uast:Position",
offset: 0,
line: 0,
col: 0,
},
Rparen: { '@type': "uast:Position",
offset: 0,
line: 0,
col: 0,
},
TokPos: { '@type': "uast:Position",
offset: 17,
line: 3,
col: 1,
},
},
Doc: ~,
Specs: [
{ '@type': "go:ValueSpec",
'@role': [Declaration],
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 23,
line: 3,
col: 7,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
},
Comment: ~,
Doc: ~,
Names: [
{ '@type': "uast:Identifier",
'@role': [Name],
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 23,
line: 3,
col: 7,
},
end: { '@type': "uast:Position",
offset: 24,
line: 3,
col: 8,
},
},
Name: "v",
},
],
Type: ~,
Values: [
{ '@type': "uast:String",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 27,
line: 3,
col: 11,
},
end: { '@type': "uast:Position",
offset: 33,
line: 3,
col: 17,
},
},
Format: "",
Value: "𝓏",
},
],
},
],
Tok: "const",
},
],
Doc: ~,
Imports: ~,
Name: { '@type': "uast:Identifier",
'@pos': { '@type': "uast:Positions",
start: { '@type': "uast:Position",
offset: 8,
line: 1,
col: 9,
},
end: { '@type': "uast:Position",
offset: 15,
line: 1,
col: 16,
},
},
Name: "unicode",
},
}
Loading

0 comments on commit 3c03f89

Please sign in to comment.