JuliaLang / JuliaSyntax.jl

The Julia compiler frontend
Other
272 stars 35 forks source link

Fix crash when parsing malformed `function(where` #388

Closed c42f closed 10 months ago

c42f commented 10 months ago

When word operators are parsed as atoms (ie, identifiers), the kind should be remapped as such. This fixes a crash when parsing function(where because was_eventually_call assumes that a kind of K"where" implies an internal node.

Part of #380

codecov[bot] commented 10 months ago

Codecov Report

Merging #388 (ef75191) into main (5757535) will increase coverage by 0.00%. The diff coverage is 100.00%.

@@           Coverage Diff           @@
##             main     #388   +/-   ##
=======================================
  Coverage   96.58%   96.58%           
=======================================
  Files          14       14           
  Lines        4185     4187    +2     
=======================================
+ Hits         4042     4044    +2     
  Misses        143      143           
Files Coverage Δ
src/parser.jl 98.10% <100.00%> (+<0.01%) :arrow_up: