Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

errors on record syntax just dumping the ast #338

Open
sdancer opened this issue Jul 31, 2020 · 2 comments
Open

errors on record syntax just dumping the ast #338

sdancer opened this issue Jul 31, 2020 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@sdancer
Copy link
Contributor

sdancer commented Jul 31, 2020

hamler: Left (RecordField (Label {lblTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 99, srcColumn = 3}, srcEnd = SourcePos {srcLine = 99, srcColumn = 13}}, tokLeadingComments = [Line LF,Space 2], tokTrailingComments = []}, tokValue = TokLowerName [] "serializer"}, lblName = "serializer"}) (SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 99, srcColumn = 13}, srcEnd = SourcePos {srcLine = 99, srcColumn = 14}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokOperator [] ":"}) (ExprLambda () (Lambda {lmbSymbol = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 99, srcColumn = 15}, srcEnd = SourcePos {srcLine = 99, srcColumn = 16}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokBackslash}, lmbBinders = BinderVar () (Name {nameTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 99, srcColumn = 16}, srcEnd = SourcePos {srcLine = 99, srcColumn = 19}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "ctx"}, nameValue = Ident {getIdent = "ctx"}}) :| [BinderVar () (Name {nameTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 99, srcColumn = 20}, srcEnd = SourcePos {srcLine = 99, srcColumn = 23}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "val"}, nameValue = Ident {getIdent = "val"}})], lmbArr = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 99, srcColumn = 24}, srcEnd = SourcePos {srcLine = 99, srcColumn = 26}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokRightArrow ASCII}, lmbBody = ExprApp () (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 5}, srcEnd = SourcePos {srcLine = 100, srcColumn = 12}}, tokLeadingComments = [Line LF,Space 4], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "bconcat"}, qualModule = Nothing, qualName = Ident {getIdent = "bconcat"}})) (ExprParens () (Wrapped {wrpOpen = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 13}, srcEnd = SourcePos {srcLine = 100, srcColumn = 14}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLeftParen}, wrpValue = ExprApp () (ExprApp () (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 14}, srcEnd = SourcePos {srcLine = 100, srcColumn = 17}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "map"}, qualModule = Nothing, qualName = Ident {getIdent = "map"}})) (ExprParens () (Wrapped {wrpOpen = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 18}, srcEnd = SourcePos {srcLine = 100, srcColumn = 19}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLeftParen}, wrpValue = ExprLambda () (Lambda {lmbSymbol = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 19}, srcEnd = SourcePos {srcLine = 100, srcColumn = 20}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokBackslash}, lmbBinders = BinderVar () (Name {nameTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 20}, srcEnd = SourcePos {srcLine = 100, srcColumn = 24}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "name"}, nameValue = Ident {getIdent = "name"}}) :| [], lmbArr = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 25}, srcEnd = SourcePos {srcLine = 100, srcColumn = 27}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokRightArrow ASCII}, lmbBody = ExprApp () (ExprApp () (ExprRecordAccessor () (RecordAccessor {recExpr = ExprParens () (Wrapped {wrpOpen = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 28}, srcEnd = SourcePos {srcLine = 100, srcColumn = 29}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLeftParen}, wrpValue = ExprApp () (ExprApp () (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 29}, srcEnd = SourcePos {srcLine = 100, srcColumn = 33}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "mget"}, qualModule = Nothing, qualName = Ident {getIdent = "mget"}})) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 34}, srcEnd = SourcePos {srcLine = 100, srcColumn = 38}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "name"}, qualModule = Nothing, qualName = Ident {getIdent = "name"}}))) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 39}, srcEnd = SourcePos {srcLine = 100, srcColumn = 42}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLowerName [] "rec"}, qualModule = Nothing, qualName = Ident {getIdent = "rec"}})), wrpClose = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 42}, srcEnd = SourcePos {srcLine = 100, srcColumn = 43}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokRightParen}}), recDot = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 43}, srcEnd = SourcePos {srcLine = 100, srcColumn = 44}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokDot}, recPath = Separated {sepHead = Label {lblTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 44}, srcEnd = SourcePos {srcLine = 100, srcColumn = 54}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "serializer"}, lblName = "serializer"}, sepTail = []}})) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 55}, srcEnd = SourcePos {srcLine = 100, srcColumn = 58}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "val"}, qualModule = Nothing, qualName = Ident {getIdent = "val"}}))) (ExprParens () (Wrapped {wrpOpen = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 59}, srcEnd = SourcePos {srcLine = 100, srcColumn = 60}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLeftParen}, wrpValue = ExprApp () (ExprApp () (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 60}, srcEnd = SourcePos {srcLine = 100, srcColumn = 64}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "mget"}, qualModule = Nothing, qualName = Ident {getIdent = "mget"}})) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 65}, srcEnd = SourcePos {srcLine = 100, srcColumn = 69}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokLowerName [] "name"}, qualModule = Nothing, qualName = Ident {getIdent = "name"}}))) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 70}, srcEnd = SourcePos {srcLine = 100, srcColumn = 73}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLowerName [] "val"}, qualModule = Nothing, qualName = Ident {getIdent = "val"}})), wrpClose = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 73}, srcEnd = SourcePos {srcLine = 100, srcColumn = 74}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokRightParen}}))}), wrpClose = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 74}, srcEnd = SourcePos {srcLine = 100, srcColumn = 75}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokRightParen}}))) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 76}, srcEnd = SourcePos {srcLine = 100, srcColumn = 81}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLowerName [] "names"}, qualModule = Nothing, qualName = Ident {getIdent = "names"}})), wrpClose = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 100, srcColumn = 81}, srcEnd = SourcePos {srcLine = 100, srcColumn = 82}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokRightParen}}))})))
CallStack (from HasCallStack):
  error, called at src/Language/PureScript/CST/Utils.hs:229:13 in purescript-0.13.6-1O3sGoyKih2KZwHFX8NLra:Language.PureScript.CST.Utils
hamler: Left (RecordField (Label {lblTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 19, srcColumn = 3}, srcEnd = SourcePos {srcLine = 19, srcColumn = 12}}, tokLeadingComments = [Line LF,Space 2], tokTrailingComments = []}, tokValue = TokLowerName [] "_point_id"}, lblName = "_point_id"}) (SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 19, srcColumn = 12}, srcEnd = SourcePos {srcLine = 19, srcColumn = 13}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokOperator [] ":"}) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 19, srcColumn = 14}, srcEnd = SourcePos {srcLine = 19, srcColumn = 19}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLowerName [] "word8"}, qualModule = Nothing, qualName = Ident {getIdent = "word8"}})))
CallStack (from HasCallStack):
  error, called at src/Language/PureScript/CST/Utils.hs:229:13 in purescript-0.13.6-1O3sGoyKih2KZwHFX8NLra:Language.PureScript.CST.Utils
hamler: Left (RecordField (Label {lblTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 15, srcColumn = 3}, srcEnd = SourcePos {srcLine = 15, srcColumn = 5}}, tokLeadingComments = [Line LF,Space 2], tokTrailingComments = []}, tokValue = TokLowerName [] "f1"}, lblName = "f1"}) (SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 15, srcColumn = 5}, srcEnd = SourcePos {srcLine = 15, srcColumn = 6}}, tokLeadingComments = [], tokTrailingComments = [Space 1]}, tokValue = TokOperator [] ":"}) (ExprIdent () (QualifiedName {qualTok = SourceToken {tokAnn = TokenAnn {tokRange = SourceRange {srcStart = SourcePos {srcLine = 15, srcColumn = 7}, srcEnd = SourcePos {srcLine = 15, srcColumn = 13}}, tokLeadingComments = [], tokTrailingComments = []}, tokValue = TokLowerName [] "word16"}, qualModule = Nothing, qualName = Ident {getIdent = "word16"}})))
CallStack (from HasCallStack):
  error, called at src/Language/PureScript/CST/Utils.hs:229:13 in purescript-0.13.6-1O3sGoyKih2KZwHFX8NLra:Language.PureScript.CST.Utils
hamler: thread blocked indefinitely in an MVar operation
@emqplus emqplus assigned emqplus and sdzx-1 and unassigned emqplus Jul 31, 2020
@emqplus emqplus added the bug Something isn't working label Jul 31, 2020
@emqplus emqplus added this to the 0.2 - OTP Behaviours milestone Jul 31, 2020
@sdzx-1
Copy link
Collaborator

sdzx-1 commented Aug 1, 2020

we add a new record syntax.
e:
t = { name = "yang", age =23}
f x = x
t1 = t{name = "wang"} -- record update
t2 = f {name="wang"}. -- function applicative
the expr: t3 = f {name : "wang"} is not support!

@sdancer sdancer changed the title hamler: thread blocked indefinitely in an MVar operation errors on record syntax just dumping the ast Aug 1, 2020
@sdancer
Copy link
Contributor Author

sdancer commented Aug 1, 2020

thanks, changing the issue title

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants