Skip to content

Commit ebfaf96

Browse files
authored
kinds: rm unused kind K"inert" (#561)
`inert` is mostly used in lowering. As far as I can tell, there is precisely one place in the flisp parser that produces it: https://github.com/JuliaLang/julia/blob/d6b3669621ceb18aea693d8544b2c38870d289ad/src/julia-parser.scm#L1259 However, we do not insert and `inert` there in JuliaSyntax, instead preferring to automatically quote the rhs of a `.` head in expr conversion: https://github.com/JuliaLang/JuliaSyntax.jl/blob/eceaa39706c6ecc3ef496613096216625dba558e/src/expr.jl#L310 As a result, (and as code coverage complains), the syntax head is unused and should be removed here. However, it should probably then be added back in JuliaLowering.
1 parent 36450b0 commit ebfaf96

File tree

2 files changed

+0
-3
lines changed

2 files changed

+0
-3
lines changed

src/expr.jl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -526,8 +526,6 @@ end
526526
elseif k == K"module"
527527
pushfirst!(args, !has_flags(nodehead, BARE_MODULE_FLAG))
528528
pushfirst!((args[3]::Expr).args, loc)
529-
elseif k == K"inert"
530-
return QuoteNode(only(args))
531529
elseif k == K"quote"
532530
if length(args) == 1
533531
a1 = only(args)

src/kinds.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1015,7 +1015,6 @@ register_kinds!(JuliaSyntax, 0, [
10151015
"dotcall"
10161016
"comparison"
10171017
"curly"
1018-
"inert" # QuoteNode; not quasiquote
10191018
"juxtapose" # Numeric juxtaposition like 2x
10201019
"string" # A string interior node (possibly containing interpolations)
10211020
"cmdstring" # A cmd string node (containing delimiters plus string)

0 commit comments

Comments
 (0)