File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -43,6 +43,8 @@ function _getindex(x::EXPR, i)
4343 x. args[i]
4444 elseif headof (x) === :export
4545 oddt_evena (x, i)
46+ elseif headof (x) === :public
47+ oddt_evena (x, i)
4648 elseif headof (x) === :filter
4749 _filter (x, i)
4850 elseif headof (x) === :flatten
Original file line number Diff line number Diff line change 744744 @test x[6 ] === x. args[3 ]
745745end
746746
747+ if VERSION > v " 1.11-"
748+ @testitem " :public" begin
749+ using CSTParser: @cst_str , headof, valof
750+
751+ x = cst " public a, b, c"
752+ @test length (x) == 6
753+ @test x[1 ] === x. trivia[1 ]
754+ @test x[2 ] === x. args[1 ]
755+ @test x[3 ] === x. trivia[2 ]
756+ @test x[4 ] === x. args[2 ]
757+ @test x[5 ] === x. trivia[3 ]
758+ @test x[6 ] === x. args[3 ]
759+ end
760+ end
761+
747762@testitem " :parameters" begin
748763 using CSTParser: @cst_str , headof, valof
749764
You can’t perform that action at this time.
0 commit comments