Safe Haskell | Safe |
---|---|
Language | Haskell98 |
- data JSExpression
- = JSIdentifier !JSAnnot !String
- | JSDecimal !JSAnnot !String
- | JSLiteral !JSAnnot !String
- | JSHexInteger !JSAnnot !String
- | JSOctal !JSAnnot !String
- | JSStringLiteral !JSAnnot !String
- | JSRegEx !JSAnnot !String
- | JSArrayLiteral !JSAnnot ![JSArrayElement] !JSAnnot
- | JSAssignExpression !JSExpression !JSAssignOp !JSExpression
- | JSCallExpression !JSExpression !JSAnnot !(JSCommaList JSExpression) !JSAnnot
- | JSCallExpressionDot !JSExpression !JSAnnot !JSExpression
- | JSCallExpressionSquare !JSExpression !JSAnnot !JSExpression !JSAnnot
- | JSCommaExpression !JSExpression !JSAnnot !JSExpression
- | JSExpressionBinary !JSExpression !JSBinOp !JSExpression
- | JSExpressionParen !JSAnnot !JSExpression !JSAnnot
- | JSExpressionPostfix !JSExpression !JSUnaryOp
- | JSExpressionTernary !JSExpression !JSAnnot !JSExpression !JSAnnot !JSExpression
- | JSFunctionExpression !JSAnnot !JSIdent !JSAnnot !(JSCommaList JSIdent) !JSAnnot !JSBlock
- | JSMemberDot !JSExpression !JSAnnot !JSExpression
- | JSMemberExpression !JSExpression !JSAnnot !(JSCommaList JSExpression) !JSAnnot
- | JSMemberNew !JSAnnot !JSExpression !JSAnnot !(JSCommaList JSExpression) !JSAnnot
- | JSMemberSquare !JSExpression !JSAnnot !JSExpression !JSAnnot
- | JSNewExpression !JSAnnot !JSExpression
- | JSObjectLiteral !JSAnnot !JSObjectPropertyList !JSAnnot
- | JSUnaryExpression !JSUnaryOp !JSExpression
- | JSVarInitExpression !JSExpression !JSVarInitializer
- data JSAnnot
- data JSBinOp
- = JSBinOpAnd !JSAnnot
- | JSBinOpBitAnd !JSAnnot
- | JSBinOpBitOr !JSAnnot
- | JSBinOpBitXor !JSAnnot
- | JSBinOpDivide !JSAnnot
- | JSBinOpEq !JSAnnot
- | JSBinOpGe !JSAnnot
- | JSBinOpGt !JSAnnot
- | JSBinOpIn !JSAnnot
- | JSBinOpInstanceOf !JSAnnot
- | JSBinOpLe !JSAnnot
- | JSBinOpLsh !JSAnnot
- | JSBinOpLt !JSAnnot
- | JSBinOpMinus !JSAnnot
- | JSBinOpMod !JSAnnot
- | JSBinOpNeq !JSAnnot
- | JSBinOpOr !JSAnnot
- | JSBinOpPlus !JSAnnot
- | JSBinOpRsh !JSAnnot
- | JSBinOpStrictEq !JSAnnot
- | JSBinOpStrictNeq !JSAnnot
- | JSBinOpTimes !JSAnnot
- | JSBinOpUrsh !JSAnnot
- data JSUnaryOp
- data JSSemi
- = JSSemi !JSAnnot
- | JSSemiAuto
- data JSAssignOp
- data JSTryCatch
- data JSTryFinally
- data JSStatement
- = JSStatementBlock !JSAnnot ![JSStatement] !JSAnnot !JSSemi
- | JSBreak !JSAnnot !JSIdent !JSSemi
- | JSConstant !JSAnnot !(JSCommaList JSExpression) !JSSemi
- | JSContinue !JSAnnot !JSIdent !JSSemi
- | JSDoWhile !JSAnnot !JSStatement !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSSemi
- | JSFor !JSAnnot !JSAnnot !(JSCommaList JSExpression) !JSAnnot !(JSCommaList JSExpression) !JSAnnot !(JSCommaList JSExpression) !JSAnnot !JSStatement
- | JSForIn !JSAnnot !JSAnnot !JSExpression !JSBinOp !JSExpression !JSAnnot !JSStatement
- | JSForVar !JSAnnot !JSAnnot !JSAnnot !(JSCommaList JSExpression) !JSAnnot !(JSCommaList JSExpression) !JSAnnot !(JSCommaList JSExpression) !JSAnnot !JSStatement
- | JSForVarIn !JSAnnot !JSAnnot !JSAnnot !JSExpression !JSBinOp !JSExpression !JSAnnot !JSStatement
- | JSFunction !JSAnnot !JSIdent !JSAnnot !(JSCommaList JSIdent) !JSAnnot !JSBlock !JSSemi
- | JSIf !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSStatement
- | JSIfElse !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSStatement !JSAnnot !JSStatement
- | JSLabelled !JSIdent !JSAnnot !JSStatement
- | JSEmptyStatement !JSAnnot
- | JSExpressionStatement !JSExpression !JSSemi
- | JSAssignStatement !JSExpression !JSAssignOp !JSExpression !JSSemi
- | JSMethodCall !JSExpression !JSAnnot !(JSCommaList JSExpression) !JSAnnot !JSSemi
- | JSReturn !JSAnnot !(Maybe JSExpression) !JSSemi
- | JSSwitch !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSAnnot ![JSSwitchParts] !JSAnnot !JSSemi
- | JSThrow !JSAnnot !JSExpression !JSSemi
- | JSTry !JSAnnot !JSBlock ![JSTryCatch] !JSTryFinally
- | JSVariable !JSAnnot !(JSCommaList JSExpression) !JSSemi
- | JSWhile !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSStatement
- | JSWith !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSStatement !JSSemi
- data JSBlock = JSBlock !JSAnnot ![JSStatement] !JSAnnot
- data JSSwitchParts
- = JSCase !JSAnnot !JSExpression !JSAnnot ![JSStatement]
- | JSDefault !JSAnnot !JSAnnot ![JSStatement]
- data JSAST
- data JSObjectProperty
- data JSPropertyName
- type JSObjectPropertyList = JSCommaTrailingList JSObjectProperty
- data JSAccessor
- data JSIdent
- data JSVarInitializer
- data JSArrayElement
- data JSCommaList a
- = JSLCons !(JSCommaList a) !JSAnnot !a
- | JSLOne !a
- | JSLNil
- data JSCommaTrailingList a
- = JSCTLComma !(JSCommaList a) !JSAnnot
- | JSCTLNone !(JSCommaList a)
- binOpEq :: JSBinOp -> JSBinOp -> Bool
- showStripped :: JSAST -> String
Documentation
data JSExpression Source #
JSAnnot !TokenPosn ![CommentAnnotation] | Annotation: position and comment/whitespace information |
JSAnnotSpace | A single space character |
JSNoAnnot | No annotation |
data JSAssignOp Source #
data JSTryCatch Source #
JSCatch !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSBlock | catch,lb,ident,rb,block |
JSCatchIf !JSAnnot !JSAnnot !JSExpression !JSAnnot !JSExpression !JSAnnot !JSBlock | catch,lb,ident,if,expr,rb,block |
data JSTryFinally Source #
JSFinally !JSAnnot !JSBlock | finally,block |
JSNoFinally |
data JSStatement Source #
JSBlock !JSAnnot ![JSStatement] !JSAnnot | lbrace, stmts, rbrace |
data JSSwitchParts Source #
JSCase !JSAnnot !JSExpression !JSAnnot ![JSStatement] | expr,colon,stmtlist |
JSDefault !JSAnnot !JSAnnot ![JSStatement] | colon,stmtlist |
JSAstProgram ![JSStatement] !JSAnnot | source elements, tailing whitespace |
JSAstStatement !JSStatement !JSAnnot | |
JSAstExpression !JSExpression !JSAnnot | |
JSAstLiteral !JSExpression !JSAnnot |
data JSObjectProperty Source #
JSPropertyAccessor !JSAccessor !JSPropertyName !JSAnnot ![JSExpression] !JSAnnot !JSBlock | (get|set), name, lb, params, rb, block |
JSPropertyNameandValue !JSPropertyName !JSAnnot ![JSExpression] | name, colon, value |
data JSPropertyName Source #
data JSAccessor Source #
Accessors for JSObjectProperty is either get
or set
.
data JSVarInitializer Source #
JSVarInit !JSAnnot !JSExpression | assignop, initializer |
JSVarInitNone |
data JSArrayElement Source #
data JSCommaList a Source #
JSLCons !(JSCommaList a) !JSAnnot !a | head, comma, a |
JSLOne !a | single element (no comma) |
JSLNil |
Eq a => Eq (JSCommaList a) Source # | |
Data a => Data (JSCommaList a) Source # | |
Show a => Show (JSCommaList a) Source # | |
data JSCommaTrailingList a Source #
JSCTLComma !(JSCommaList a) !JSAnnot | list, trailing comma |
JSCTLNone !(JSCommaList a) | list |
Eq a => Eq (JSCommaTrailingList a) Source # | |
Data a => Data (JSCommaTrailingList a) Source # | |
Show a => Show (JSCommaTrailingList a) Source # | |
showStripped :: JSAST -> String Source #
Show the AST elements stipped of their JSAnnot data.