[Github-comments] [geany/geany] Create julia lexer and tags parser (#2584)

getzze notifications at xxxxx
Thu Dec 31 14:09:23 UTC 2020


@AndiMD Thanks for reporting these problems! I think it would be great to announce it on Julia discourse.

>     1. Highlighting interpolated strings seems inconsistent: Depending on using `$(var)` vs `$var` and single quote vs triple quote strings, I see different results. Example:
>        `"($scanPosX,$scanPosY): (k±Δk)=$(kLaserApprox) $(begin x+5 end)"`
>        `"""($scanPosX,$scanPosY): (k±Δk)=$(kLaserApprox)  $(begin x+5 end)"""`

Interpolation highlighting is only done for single-quote strings, but I am planning to allow it in triple-quote and commands also.
For `$(var)` vs `$var`, I didn't find a way to highlight `$(` in the former so I ended up highlighting only what is inside the parenthesis. Because in the latter case there are no parenthesis, nothing is highlighted. I can try to find a way to highlight both, including the `$`.


>     2. Macros confuse the lexer (possibly we have to live with that, since macros can have arbitrary syntax)
>        Example:
> Base. at kwdef struct A
>     a::Float64 = 1E-19 
>     b::Float64 = 1E-22 
> end
> ```
> 

Thanks for reporting, that are actually two bugs:
- defined values for the attributes are not parsed at all
- `Base. at kwdef` is not recognized as a macro (`@kwdef` is well recognized):

```julia
@eval fun1(x) = $pi        # recognizes `fun1` short function definition
Base. at eval fun1(x) = $pi   # does not recognize `fun1` short function definition
```


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/2584#issuecomment-752967802
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20201231/b94a14e5/attachment.htm>


More information about the Github-comments mailing list