Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/c9s/c6
/ functions
Functions
854 in github.com/c9s/c6
⨍
Functions
854
◇
Types & classes
118
↓ 154 callers
Method
next
next returns the next rune in the input.
lexer/lexer.go:201
↓ 106 callers
Method
emit
* Emit a token to the channel emit(ast.T_SEMICOLON) emit(ast.T_PSEUDO_SELECTOR, true) // contains interpolation */
lexer/lexer.go:306
↓ 98 callers
Function
RunParserTest
(code string)
parser/parser_test.go:13
↓ 91 callers
Function
AssertLexerTokenSequence
(t *testing.T, scss string, tokenList []ast.TokenType)
lexer/test_utils.go:16
↓ 67 callers
Method
String
()
ast/expr.go:4
↓ 55 callers
Function
NewLexerWithString
** Create a lexer object with string */
lexer/lexer.go:82
↓ 51 callers
Method
expect
(tokenType ast.TokenType)
parser/parser.go:158
↓ 50 callers
Method
Run
()
lexer/lexer.go:471
↓ 49 callers
Method
Close
()
lexer/lexer.go:479
↓ 47 callers
Method
peek
peek returns but does not consume the next rune in the input.
lexer/lexer.go:223
↓ 46 callers
Method
peek
()
parser/parser.go:205
↓ 44 callers
Method
accept
accept() accepts one token type one time. rolls back if the token type mismatch
parser/parser.go:118
↓ 44 callers
Method
backup
backup steps back one rune. Can be called only once per call of next.
lexer/lexer.go:216
↓ 40 callers
Function
AssertTokenSequence
(t *testing.T, l *Lexer, tokenList []ast.TokenType)
lexer/test_utils.go:37
↓ 35 callers
Function
debug
(format string, args ...interface{})
parser/parser.go:22
↓ 27 callers
Function
AssertLexerTokenSequenceFromState
(t *testing.T, scss string, fn stateFn, tokenList []ast.TokenType)
lexer/test_utils.go:7
↓ 26 callers
Method
next
()
parser/parser.go:171
↓ 25 callers
Method
ignoreSpaces
* ignore space characters return true if there is space */
lexer/lexer.go:407
↓ 24 callers
Method
errorf
(msg string, r rune)
lexer/lexer_state.go:14
↓ 21 callers
Method
ParseExpr
** We here treat the property values as expressions: padding: {expression} {expression} {expression}; margin: {expression}; */
parser/rules.go:709
↓ 21 callers
Method
match
lookahead match method to match a string
lexer/lexer.go:332
↓ 20 callers
Function
lexExpr
* Lexing expression with interpolation support. */
lexer/lexer_expr.go:9
↓ 17 callers
Function
NewParser
(context *runtime.Context)
parser/parser.go:64
↓ 17 callers
Method
ParseScss
(code string)
parser/rules.go:62
↓ 16 callers
Method
accept
test the next character, if it's not matched, go back to the original offset. Note, this method only match the first character
lexer/lexer.go:149
↓ 15 callers
Method
advance
()
parser/parser.go:197
↓ 13 callers
Method
ignore
ignore skips over the pending input before this point.
lexer/lexer.go:327
↓ 13 callers
Method
restore
(pos int)
parser/parser.go:103
↓ 12 callers
Method
TokenStream
()
lexer/lexer.go:111
↓ 11 callers
Method
Append
(expr Expr)
ast/list.go:33
↓ 10 callers
Method
ParseDeclBlock
()
parser/rules.go:1177
↓ 9 callers
Function
AssertCompile
(t *testing.T, code string, expected string)
compiler/compact_compiler_test.go:8
↓ 9 callers
Function
IsInterpolationStartToken
(r rune, r2 rune)
lexer/lexer_selector.go:7
↓ 9 callers
Method
backup
()
parser/parser.go:99
↓ 9 callers
Function
uintsub
(a, b uint32)
runtime/color.go:24
↓ 8 callers
Function
Compute
(op *ast.Op, a ast.Value, b ast.Value)
runtime/compute.go:60
↓ 7 callers
Function
lexInterpolation
* There are 3 scope that users may use interpolation syntax: {selector interpolation} { {property name inpterpolation}: {property value interpola
lexer/lexer_interpolation.go:15
↓ 7 callers
Method
peekBy
peek more characters peekBy(1) == peek()
lexer/lexer.go:249
↓ 6 callers
Method
Boolean
()
ast/boolean.go:6
↓ 6 callers
Method
Hex
()
ast/color_rgba.go:57
↓ 6 callers
Function
IsComparable
(av ast.Value, bv ast.Value)
runtime/compare.go:5
↓ 6 callers
Method
remember
remember the current offset, can be rolled back by using the `rollback` method
lexer/lexer.go:121
↓ 6 callers
Method
rollback
rollback reset the offset to the backup point (this is a rune-wise rollback)
lexer/lexer.go:128
↓ 5 callers
Function
EvaluateUnaryExpr
(expr *ast.UnaryExpr, context *Context)
runtime/compute.go:488
↓ 5 callers
Function
HexToRGBA
HexToRGB converts an Hex string to a RGB triple.
ast/color.go:45
↓ 5 callers
Method
Len
()
ast/list.go:29
↓ 5 callers
Method
expect
(valid string)
lexer/lexer.go:140
↓ 5 callers
Function
lexComment
(l *Lexer, emit bool)
lexer/lexer_comment.go:52
↓ 5 callers
Method
matchKeywordList
(keywords ast.KeywordTokenList)
lexer/lexer.go:365
↓ 4 callers
Function
EvaluateBinaryExpr
* EvaluateBinaryExpr recursively. */
runtime/compute.go:444
↓ 4 callers
Method
GetVariable
(name string)
runtime/context.go:62
↓ 4 callers
Method
HasCompliant
(compliant int)
compiler/compact_compiler.go:51
↓ 4 callers
Function
IsValue
* This function returns true when the val is a scalar value, not an expression. */
runtime/compute.go:322
↓ 4 callers
Function
NewRGBAColor
(r, g, b uint32, a float32, token *Token)
ast/color_rgba.go:35
↓ 4 callers
Function
OutputRed
(t *testing.T, msg string, args ...interface{})
lexer/test_utils.go:31
↓ 4 callers
Method
RGBColor
()
ast/color_hsl.go:27
↓ 4 callers
Method
acceptAnyOf2
(tokType1, tokType2 ast.TokenType)
parser/parser.go:140
↓ 4 callers
Method
createToken
(tokenType ast.TokenType)
lexer/lexer.go:283
↓ 4 callers
Method
emitToken
(token *ast.Token)
lexer/lexer.go:264
↓ 4 callers
Method
length
Return the length of the current token
lexer/lexer.go:191
↓ 4 callers
Function
lexString
(l *Lexer)
lexer/lexer_string.go:7
↓ 4 callers
Method
peek2
()
lexer/lexer.go:229
↓ 4 callers
Method
til
(str string)
lexer/lexer.go:315
↓ 3 callers
Function
ConvertHUE
(p, q, t float64)
ast/color_hsl.go:92
↓ 3 callers
Function
EvaluateUnaryExprInBooleanContext
(expr *ast.UnaryExpr, context *Context)
runtime/compute.go:380
↓ 3 callers
Function
NewRGBColor
(r, g, b uint32, token *Token)
ast/color_rgba.go:65
↓ 3 callers
Method
ParseCondition
* The operator precedence is described here @see http://introcs.cs.princeton.edu/java/11precedence/ */
parser/rules.go:205
↓ 3 callers
Method
ParseFunctionPrototype
()
parser/rules.go:1623
↓ 3 callers
Method
ParseList
()
parser/rules.go:941
↓ 3 callers
Method
ParseLogicExpr
()
parser/rules.go:216
↓ 3 callers
Method
ParseStmts
()
parser/rules.go:89
↓ 3 callers
Method
ParseTerm
()
parser/rules.go:678
↓ 3 callers
Method
ParseVariable
()
parser/rules.go:999
↓ 3 callers
Method
ReadFile
()
ast/file.go:21
↓ 3 callers
Method
Set
(key Expr, val Expr)
ast/map.go:13
↓ 3 callers
Method
TopRuleSet
()
runtime/context.go:55
↓ 3 callers
Method
lastToken
()
lexer/lexer.go:58
↓ 3 callers
Function
lexInterpolation2
Lex the expression inside interpolation
lexer/lexer_interpolation.go:54
↓ 3 callers
Function
lexVariableName
$var-rgba(255,255,0)
lexer/lexer_var.go:9
↓ 2 callers
Method
Add
type ArgumentList []*Argument
ast/argument_list.go:10
↓ 2 callers
Method
CompileStmt
(anyStm ast.Stmt)
compiler/compact_compiler.go:82
↓ 2 callers
Method
DispatchFn
(fn stateFn)
lexer/lexer.go:447
↓ 2 callers
Method
EnableCompliant
* * Enable compliant */
compiler/compact_compiler.go:40
↓ 2 callers
Method
Get
(key Expr)
ast/map.go:21
↓ 2 callers
Function
HSLToRGB
* h = 0~360 s = 0~1 l = 0~1 */
ast/color_hsl.go:67
↓ 2 callers
Function
HSVToRGB
(h, s, v float64)
ast/color_hsv.go:72
↓ 2 callers
Function
HexColorAddNumber
(c *ast.HexColor, num *ast.Number)
runtime/color.go:10
↓ 2 callers
Method
IsCssSlash
** The the divide expression will only be evaluated in the following 3 conditions: 1. If the value, or any part of it, is stored in a variable or re
ast/expr.go:67
↓ 2 callers
Function
IsSelector
(t ast.TokenType)
lexer/lexer_selector.go:16
↓ 2 callers
Function
NewClassSelector
(className string)
ast/selector.go:64
↓ 2 callers
Function
NewCompactCompiler
(context *runtime.Context)
compiler/compact_compiler.go:29
↓ 2 callers
Function
NewHSLColor
(h, s, v float64, token *Token)
ast/color_hsl.go:36
↓ 2 callers
Function
NewHSVColor
(h, s, v float64, token *Token)
ast/color_hsv.go:35
↓ 2 callers
Function
NewHexColor
(hex string, token *Token)
ast/color.go:39
↓ 2 callers
Function
NewNumber
(num float64, unit *Unit, token *Token)
ast/number.go:12
↓ 2 callers
Function
NewUnit
(unitType TokenType, token *Token)
ast/unit.go:10
↓ 2 callers
Function
OutputGreen
(t *testing.T, msg string, args ...interface{})
lexer/test_utils.go:25
↓ 2 callers
Method
ParseCommaSepList
()
parser/rules.go:951
↓ 2 callers
Method
ParseComparisonExpr
()
parser/rules.go:239
↓ 2 callers
Method
ParseComplexSelector
(parentRuleSet *ast.RuleSet)
parser/rules.go:353
next →
1–100 of 854, ranked by callers